@digiteers/uloba3-sdk 4.2.2 → 4.2.4

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.
Files changed (39) hide show
  1. package/.github/ISSUE_TEMPLATE/bug_report.yml +167 -0
  2. package/.github/ISSUE_TEMPLATE/config.yml +11 -0
  3. package/.github/ISSUE_TEMPLATE/feature_request.yml +109 -0
  4. package/.github/pull_request_template.md +99 -0
  5. package/dist/api/applications.d.ts +3 -6
  6. package/dist/api/applications.d.ts.map +1 -1
  7. package/dist/api/applications.js +3 -12
  8. package/dist/api/applications.js.map +1 -1
  9. package/dist/api/assistants.d.ts.map +1 -1
  10. package/dist/api/contracts.d.ts +3 -18
  11. package/dist/api/contracts.d.ts.map +1 -1
  12. package/dist/api/contracts.js +3 -28
  13. package/dist/api/contracts.js.map +1 -1
  14. package/dist/api/data-products.d.ts +20 -0
  15. package/dist/api/data-products.d.ts.map +1 -1
  16. package/dist/api/data-products.js.map +1 -1
  17. package/dist/api/inquiries.d.ts +3 -25
  18. package/dist/api/inquiries.d.ts.map +1 -1
  19. package/dist/api/inquiries.js +3 -45
  20. package/dist/api/inquiries.js.map +1 -1
  21. package/dist/api/invites.d.ts +16 -11
  22. package/dist/api/invites.d.ts.map +1 -1
  23. package/dist/api/invites.js +11 -21
  24. package/dist/api/invites.js.map +1 -1
  25. package/dist/api/jobs.d.ts +3 -11
  26. package/dist/api/jobs.d.ts.map +1 -1
  27. package/dist/api/jobs.js +3 -28
  28. package/dist/api/jobs.js.map +1 -1
  29. package/dist/api/overview.d.ts +6 -0
  30. package/dist/api/overview.d.ts.map +1 -1
  31. package/dist/api/overview.js +11 -0
  32. package/dist/api/overview.js.map +1 -1
  33. package/dist/constants.d.ts +4 -0
  34. package/dist/constants.d.ts.map +1 -1
  35. package/dist/constants.js +7 -3
  36. package/dist/constants.js.map +1 -1
  37. package/dist/types.d.ts +864 -2747
  38. package/dist/types.d.ts.map +1 -1
  39. package/package.json +1 -1
package/dist/types.d.ts CHANGED
@@ -2140,287 +2140,6 @@ export interface paths {
2140
2140
  patch?: never;
2141
2141
  trace?: never;
2142
2142
  };
2143
- '/api/users/{id}/activity/engagement': {
2144
- parameters: {
2145
- query?: never;
2146
- header?: never;
2147
- path?: never;
2148
- cookie?: never;
2149
- };
2150
- /**
2151
- * Get user engagement score
2152
- * @description Get comprehensive engagement metrics. Users can view their own score, support staff can view any.
2153
- */
2154
- get: {
2155
- parameters: {
2156
- query?: {
2157
- days?: number;
2158
- };
2159
- header?: never;
2160
- path: {
2161
- id: string;
2162
- };
2163
- cookie?: never;
2164
- };
2165
- requestBody?: never;
2166
- responses: {
2167
- /** @description Default Response */
2168
- 200: {
2169
- headers: {
2170
- [name: string]: unknown;
2171
- };
2172
- content: {
2173
- 'application/json': {
2174
- data: unknown;
2175
- metadata: {
2176
- viewerContext: string;
2177
- timestamp: string;
2178
- };
2179
- };
2180
- };
2181
- };
2182
- /** @description Default Response */
2183
- 401: {
2184
- headers: {
2185
- [name: string]: unknown;
2186
- };
2187
- content: {
2188
- 'application/json': {
2189
- error: string;
2190
- };
2191
- };
2192
- };
2193
- /** @description Default Response */
2194
- 403: {
2195
- headers: {
2196
- [name: string]: unknown;
2197
- };
2198
- content: {
2199
- 'application/json': {
2200
- error: string;
2201
- };
2202
- };
2203
- };
2204
- };
2205
- };
2206
- put?: never;
2207
- post?: never;
2208
- delete?: never;
2209
- options?: never;
2210
- head?: never;
2211
- patch?: never;
2212
- trace?: never;
2213
- };
2214
- '/api/users/{id}/sessions/active': {
2215
- parameters: {
2216
- query?: never;
2217
- header?: never;
2218
- path?: never;
2219
- cookie?: never;
2220
- };
2221
- /**
2222
- * Get user active sessions
2223
- * @description Get all active sessions for a user. Users can view their own sessions, support staff can view any.
2224
- */
2225
- get: {
2226
- parameters: {
2227
- query?: never;
2228
- header?: never;
2229
- path: {
2230
- id: string;
2231
- };
2232
- cookie?: never;
2233
- };
2234
- requestBody?: never;
2235
- responses: {
2236
- /** @description Default Response */
2237
- 200: {
2238
- headers: {
2239
- [name: string]: unknown;
2240
- };
2241
- content: {
2242
- 'application/json': {
2243
- data: unknown[];
2244
- metadata: {
2245
- viewerContext: string;
2246
- timestamp: string;
2247
- };
2248
- };
2249
- };
2250
- };
2251
- /** @description Default Response */
2252
- 401: {
2253
- headers: {
2254
- [name: string]: unknown;
2255
- };
2256
- content: {
2257
- 'application/json': {
2258
- error: string;
2259
- };
2260
- };
2261
- };
2262
- /** @description Default Response */
2263
- 403: {
2264
- headers: {
2265
- [name: string]: unknown;
2266
- };
2267
- content: {
2268
- 'application/json': {
2269
- error: string;
2270
- };
2271
- };
2272
- };
2273
- };
2274
- };
2275
- put?: never;
2276
- post?: never;
2277
- delete?: never;
2278
- options?: never;
2279
- head?: never;
2280
- patch?: never;
2281
- trace?: never;
2282
- };
2283
- '/api/users/{id}/sessions/history': {
2284
- parameters: {
2285
- query?: never;
2286
- header?: never;
2287
- path?: never;
2288
- cookie?: never;
2289
- };
2290
- /**
2291
- * Get user session history
2292
- * @description Get paginated session history. Users can view their own history, support staff can view any.
2293
- */
2294
- get: {
2295
- parameters: {
2296
- query?: {
2297
- limit?: number;
2298
- offset?: number;
2299
- };
2300
- header?: never;
2301
- path: {
2302
- id: string;
2303
- };
2304
- cookie?: never;
2305
- };
2306
- requestBody?: never;
2307
- responses: {
2308
- /** @description Default Response */
2309
- 200: {
2310
- headers: {
2311
- [name: string]: unknown;
2312
- };
2313
- content: {
2314
- 'application/json': {
2315
- data: unknown[];
2316
- pagination: {
2317
- limit: number;
2318
- offset: number;
2319
- has_more: boolean;
2320
- };
2321
- metadata: {
2322
- viewerContext: string;
2323
- timestamp: string;
2324
- };
2325
- };
2326
- };
2327
- };
2328
- /** @description Default Response */
2329
- 401: {
2330
- headers: {
2331
- [name: string]: unknown;
2332
- };
2333
- content: {
2334
- 'application/json': {
2335
- error: string;
2336
- };
2337
- };
2338
- };
2339
- /** @description Default Response */
2340
- 403: {
2341
- headers: {
2342
- [name: string]: unknown;
2343
- };
2344
- content: {
2345
- 'application/json': {
2346
- error: string;
2347
- };
2348
- };
2349
- };
2350
- };
2351
- };
2352
- put?: never;
2353
- post?: never;
2354
- delete?: never;
2355
- options?: never;
2356
- head?: never;
2357
- patch?: never;
2358
- trace?: never;
2359
- };
2360
- '/api/users/me/sessions/history': {
2361
- parameters: {
2362
- query?: never;
2363
- header?: never;
2364
- path?: never;
2365
- cookie?: never;
2366
- };
2367
- /**
2368
- * Get current user session history
2369
- * @description Get paginated session history for the authenticated user
2370
- */
2371
- get: {
2372
- parameters: {
2373
- query?: {
2374
- limit?: number;
2375
- offset?: number;
2376
- };
2377
- header?: never;
2378
- path?: never;
2379
- cookie?: never;
2380
- };
2381
- requestBody?: never;
2382
- responses: {
2383
- /** @description Default Response */
2384
- 200: {
2385
- headers: {
2386
- [name: string]: unknown;
2387
- };
2388
- content: {
2389
- 'application/json': {
2390
- data: unknown[];
2391
- pagination: {
2392
- limit: number;
2393
- offset: number;
2394
- has_more: boolean;
2395
- };
2396
- metadata: {
2397
- viewerContext: string;
2398
- timestamp: string;
2399
- };
2400
- };
2401
- };
2402
- };
2403
- /** @description Default Response */
2404
- 401: {
2405
- headers: {
2406
- [name: string]: unknown;
2407
- };
2408
- content: {
2409
- 'application/json': {
2410
- error: string;
2411
- };
2412
- };
2413
- };
2414
- };
2415
- };
2416
- put?: never;
2417
- post?: never;
2418
- delete?: never;
2419
- options?: never;
2420
- head?: never;
2421
- patch?: never;
2422
- trace?: never;
2423
- };
2424
2143
  '/api/users/me': {
2425
2144
  parameters: {
2426
2145
  query?: never;
@@ -6011,6 +5730,7 @@ export interface paths {
6011
5730
  approved_at?: string | null;
6012
5731
  rejected_at?: string | null;
6013
5732
  cancelled_at?: string | null;
5733
+ contracted_at?: string | null;
6014
5734
  submitted_by?: string | null;
6015
5735
  submitted_by_name?: string | null;
6016
5736
  approved_by?: string | null;
@@ -6049,6 +5769,7 @@ export interface paths {
6049
5769
  coordinator_exists?: boolean | null;
6050
5770
  can_reapply?: boolean | null;
6051
5771
  has_contract?: boolean | null;
5772
+ contract_id?: string | null;
6052
5773
  attachments?: {
6053
5774
  /** Format: uuid */
6054
5775
  id: string;
@@ -7832,342 +7553,6 @@ export interface paths {
7832
7553
  patch?: never;
7833
7554
  trace?: never;
7834
7555
  };
7835
- '/api/jobs/teamlead/stats': {
7836
- parameters: {
7837
- query?: never;
7838
- header?: never;
7839
- path?: never;
7840
- cookie?: never;
7841
- };
7842
- /**
7843
- * Get job statistics for team leaders
7844
- * @description Get job statistics with alerts for team leader role
7845
- */
7846
- get: {
7847
- parameters: {
7848
- query?: never;
7849
- header?: never;
7850
- path?: never;
7851
- cookie?: never;
7852
- };
7853
- requestBody?: never;
7854
- responses: {
7855
- /** @description Standard statistics response wrapper */
7856
- 200: {
7857
- headers: {
7858
- [name: string]: unknown;
7859
- };
7860
- content: {
7861
- 'application/json': {
7862
- /** @description Complete job statistics data */
7863
- data: {
7864
- /** @description Job counts by status */
7865
- byStatus: {
7866
- /** @description Non-negative integer (0 or greater) */
7867
- draft: number;
7868
- /** @description Non-negative integer (0 or greater) */
7869
- published: number;
7870
- /** @description Non-negative integer (0 or greater) */
7871
- unpublished: number;
7872
- /** @description Non-negative integer (0 or greater) */
7873
- expired: number;
7874
- /** @description Non-negative integer (0 or greater) */
7875
- archived?: number;
7876
- };
7877
- /** @description Job total counts and metrics */
7878
- totals: {
7879
- /** @description Non-negative integer (0 or greater) */
7880
- published: number;
7881
- /** @description Non-negative integer (0 or greater) */
7882
- expiringSoon: number;
7883
- /** @description Non-negative integer (0 or greater) */
7884
- draft: number;
7885
- /** @description Non-negative integer (0 or greater) */
7886
- expired: number;
7887
- /** @description Non-negative integer (0 or greater) */
7888
- all: number;
7889
- /** @description Non-negative integer (0 or greater) */
7890
- active: number;
7891
- /** @description Non-negative integer (0 or greater) */
7892
- needsAction?: number;
7893
- /** @description Non-negative integer (0 or greater) */
7894
- inProgress?: number;
7895
- /** @description Non-negative integer (0 or greater) */
7896
- applicationsReceived?: number;
7897
- };
7898
- alerts?: {
7899
- type: 'info' | 'warning' | 'error';
7900
- severity: 'low' | 'medium' | 'high';
7901
- /** @description Non-negative integer (0 or greater) */
7902
- count: number;
7903
- message: string;
7904
- status: string;
7905
- }[];
7906
- };
7907
- /** @description Metadata about the statistics query and response */
7908
- metadata: {
7909
- /** @description Role context for the statistics query */
7910
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
7911
- /**
7912
- * Format: uuid
7913
- * @description UUID version 4 identifier
7914
- */
7915
- accountId?: string;
7916
- /**
7917
- * Format: uuid
7918
- * @description UUID version 4 identifier
7919
- */
7920
- userId?: string;
7921
- /**
7922
- * Format: date-time
7923
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
7924
- */
7925
- queriedAt: string;
7926
- /** @description Whether the result was served from cache */
7927
- cached?: boolean;
7928
- /**
7929
- * Format: date-time
7930
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
7931
- */
7932
- cacheExpiresAt?: string;
7933
- };
7934
- };
7935
- };
7936
- };
7937
- };
7938
- };
7939
- put?: never;
7940
- post?: never;
7941
- delete?: never;
7942
- options?: never;
7943
- head?: never;
7944
- patch?: never;
7945
- trace?: never;
7946
- };
7947
- '/api/jobs/assistant/stats': {
7948
- parameters: {
7949
- query?: never;
7950
- header?: never;
7951
- path?: never;
7952
- cookie?: never;
7953
- };
7954
- /**
7955
- * Get job statistics for assistants
7956
- * @description Get job statistics with alerts for assistant role
7957
- */
7958
- get: {
7959
- parameters: {
7960
- query?: never;
7961
- header?: never;
7962
- path?: never;
7963
- cookie?: never;
7964
- };
7965
- requestBody?: never;
7966
- responses: {
7967
- /** @description Standard statistics response wrapper */
7968
- 200: {
7969
- headers: {
7970
- [name: string]: unknown;
7971
- };
7972
- content: {
7973
- 'application/json': {
7974
- /** @description Complete job statistics data */
7975
- data: {
7976
- /** @description Job counts by status */
7977
- byStatus: {
7978
- /** @description Non-negative integer (0 or greater) */
7979
- draft: number;
7980
- /** @description Non-negative integer (0 or greater) */
7981
- published: number;
7982
- /** @description Non-negative integer (0 or greater) */
7983
- unpublished: number;
7984
- /** @description Non-negative integer (0 or greater) */
7985
- expired: number;
7986
- /** @description Non-negative integer (0 or greater) */
7987
- archived?: number;
7988
- };
7989
- /** @description Job total counts and metrics */
7990
- totals: {
7991
- /** @description Non-negative integer (0 or greater) */
7992
- published: number;
7993
- /** @description Non-negative integer (0 or greater) */
7994
- expiringSoon: number;
7995
- /** @description Non-negative integer (0 or greater) */
7996
- draft: number;
7997
- /** @description Non-negative integer (0 or greater) */
7998
- expired: number;
7999
- /** @description Non-negative integer (0 or greater) */
8000
- all: number;
8001
- /** @description Non-negative integer (0 or greater) */
8002
- active: number;
8003
- /** @description Non-negative integer (0 or greater) */
8004
- needsAction?: number;
8005
- /** @description Non-negative integer (0 or greater) */
8006
- inProgress?: number;
8007
- /** @description Non-negative integer (0 or greater) */
8008
- applicationsReceived?: number;
8009
- };
8010
- alerts?: {
8011
- type: 'info' | 'warning' | 'error';
8012
- severity: 'low' | 'medium' | 'high';
8013
- /** @description Non-negative integer (0 or greater) */
8014
- count: number;
8015
- message: string;
8016
- status: string;
8017
- }[];
8018
- };
8019
- /** @description Metadata about the statistics query and response */
8020
- metadata: {
8021
- /** @description Role context for the statistics query */
8022
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
8023
- /**
8024
- * Format: uuid
8025
- * @description UUID version 4 identifier
8026
- */
8027
- accountId?: string;
8028
- /**
8029
- * Format: uuid
8030
- * @description UUID version 4 identifier
8031
- */
8032
- userId?: string;
8033
- /**
8034
- * Format: date-time
8035
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
8036
- */
8037
- queriedAt: string;
8038
- /** @description Whether the result was served from cache */
8039
- cached?: boolean;
8040
- /**
8041
- * Format: date-time
8042
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
8043
- */
8044
- cacheExpiresAt?: string;
8045
- };
8046
- };
8047
- };
8048
- };
8049
- };
8050
- };
8051
- put?: never;
8052
- post?: never;
8053
- delete?: never;
8054
- options?: never;
8055
- head?: never;
8056
- patch?: never;
8057
- trace?: never;
8058
- };
8059
- '/api/jobs/stats': {
8060
- parameters: {
8061
- query?: never;
8062
- header?: never;
8063
- path?: never;
8064
- cookie?: never;
8065
- };
8066
- /**
8067
- * Get job statistics
8068
- * @description Get statistics for jobs by status with role-based filtering
8069
- */
8070
- get: {
8071
- parameters: {
8072
- query?: never;
8073
- header?: never;
8074
- path?: never;
8075
- cookie?: never;
8076
- };
8077
- requestBody?: never;
8078
- responses: {
8079
- /** @description Standard statistics response wrapper */
8080
- 200: {
8081
- headers: {
8082
- [name: string]: unknown;
8083
- };
8084
- content: {
8085
- 'application/json': {
8086
- /** @description Complete job statistics data */
8087
- data: {
8088
- /** @description Job counts by status */
8089
- byStatus: {
8090
- /** @description Non-negative integer (0 or greater) */
8091
- draft: number;
8092
- /** @description Non-negative integer (0 or greater) */
8093
- published: number;
8094
- /** @description Non-negative integer (0 or greater) */
8095
- unpublished: number;
8096
- /** @description Non-negative integer (0 or greater) */
8097
- expired: number;
8098
- /** @description Non-negative integer (0 or greater) */
8099
- archived?: number;
8100
- };
8101
- /** @description Job total counts and metrics */
8102
- totals: {
8103
- /** @description Non-negative integer (0 or greater) */
8104
- published: number;
8105
- /** @description Non-negative integer (0 or greater) */
8106
- expiringSoon: number;
8107
- /** @description Non-negative integer (0 or greater) */
8108
- draft: number;
8109
- /** @description Non-negative integer (0 or greater) */
8110
- expired: number;
8111
- /** @description Non-negative integer (0 or greater) */
8112
- all: number;
8113
- /** @description Non-negative integer (0 or greater) */
8114
- active: number;
8115
- /** @description Non-negative integer (0 or greater) */
8116
- needsAction?: number;
8117
- /** @description Non-negative integer (0 or greater) */
8118
- inProgress?: number;
8119
- /** @description Non-negative integer (0 or greater) */
8120
- applicationsReceived?: number;
8121
- };
8122
- alerts?: {
8123
- type: 'info' | 'warning' | 'error';
8124
- severity: 'low' | 'medium' | 'high';
8125
- /** @description Non-negative integer (0 or greater) */
8126
- count: number;
8127
- message: string;
8128
- status: string;
8129
- }[];
8130
- };
8131
- /** @description Metadata about the statistics query and response */
8132
- metadata: {
8133
- /** @description Role context for the statistics query */
8134
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
8135
- /**
8136
- * Format: uuid
8137
- * @description UUID version 4 identifier
8138
- */
8139
- accountId?: string;
8140
- /**
8141
- * Format: uuid
8142
- * @description UUID version 4 identifier
8143
- */
8144
- userId?: string;
8145
- /**
8146
- * Format: date-time
8147
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
8148
- */
8149
- queriedAt: string;
8150
- /** @description Whether the result was served from cache */
8151
- cached?: boolean;
8152
- /**
8153
- * Format: date-time
8154
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
8155
- */
8156
- cacheExpiresAt?: string;
8157
- };
8158
- };
8159
- };
8160
- };
8161
- };
8162
- };
8163
- put?: never;
8164
- post?: never;
8165
- delete?: never;
8166
- options?: never;
8167
- head?: never;
8168
- patch?: never;
8169
- trace?: never;
8170
- };
8171
7556
  '/api/assistants/me/status': {
8172
7557
  parameters: {
8173
7558
  query?: never;
@@ -11030,7 +10415,7 @@ export interface paths {
11030
10415
  * InquiryStatus
11031
10416
  * @description Business status of an inquiry in the workflow
11032
10417
  */
11033
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
10418
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
11034
10419
  /**
11035
10420
  * InquiryLifecycleStatus
11036
10421
  * @description Data lifecycle status for GDPR compliance
@@ -11067,6 +10452,7 @@ export interface paths {
11067
10452
  declined_at?: string | null;
11068
10453
  cancelled_message?: string | null;
11069
10454
  cancelled_at?: string | null;
10455
+ contracted_at?: string | null;
11070
10456
  expires_at?: string | null;
11071
10457
  inquiry_number?: number | null;
11072
10458
  archived_by_inquirer?: boolean | null;
@@ -11180,6 +10566,8 @@ export interface paths {
11180
10566
  has_job_reference?: boolean | null;
11181
10567
  has_response?: boolean | null;
11182
10568
  is_pending_response?: boolean | null;
10569
+ has_contract?: boolean | null;
10570
+ contract_id?: string | null;
11183
10571
  attachments?: {
11184
10572
  /** Format: uuid */
11185
10573
  id: string;
@@ -11294,7 +10682,7 @@ export interface paths {
11294
10682
  * InquiryStatus
11295
10683
  * @description Business status of an inquiry in the workflow
11296
10684
  */
11297
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
10685
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
11298
10686
  /**
11299
10687
  * InquiryLifecycleStatus
11300
10688
  * @description Data lifecycle status for GDPR compliance
@@ -11331,6 +10719,7 @@ export interface paths {
11331
10719
  declined_at?: string | null;
11332
10720
  cancelled_message?: string | null;
11333
10721
  cancelled_at?: string | null;
10722
+ contracted_at?: string | null;
11334
10723
  expires_at?: string | null;
11335
10724
  inquiry_number?: number | null;
11336
10725
  archived_by_inquirer?: boolean | null;
@@ -11444,6 +10833,8 @@ export interface paths {
11444
10833
  has_job_reference?: boolean | null;
11445
10834
  has_response?: boolean | null;
11446
10835
  is_pending_response?: boolean | null;
10836
+ has_contract?: boolean | null;
10837
+ contract_id?: string | null;
11447
10838
  attachments?: {
11448
10839
  /** Format: uuid */
11449
10840
  id: string;
@@ -11663,6 +11054,7 @@ export interface paths {
11663
11054
  approved_at?: string | null;
11664
11055
  rejected_at?: string | null;
11665
11056
  cancelled_at?: string | null;
11057
+ contracted_at?: string | null;
11666
11058
  submitted_by?: string | null;
11667
11059
  submitted_by_name?: string | null;
11668
11060
  approved_by?: string | null;
@@ -11701,6 +11093,7 @@ export interface paths {
11701
11093
  coordinator_exists?: boolean | null;
11702
11094
  can_reapply?: boolean | null;
11703
11095
  has_contract?: boolean | null;
11096
+ contract_id?: string | null;
11704
11097
  }[];
11705
11098
  pagination: {
11706
11099
  total: number;
@@ -11789,6 +11182,7 @@ export interface paths {
11789
11182
  employer_email?: string | null;
11790
11183
  can_reapply?: boolean | null;
11791
11184
  has_contract?: boolean | null;
11185
+ contract_id?: string | null;
11792
11186
  }[];
11793
11187
  pagination: {
11794
11188
  total: number;
@@ -11877,6 +11271,7 @@ export interface paths {
11877
11271
  employer_email?: string | null;
11878
11272
  can_reapply?: boolean | null;
11879
11273
  has_contract?: boolean | null;
11274
+ contract_id?: string | null;
11880
11275
  }[];
11881
11276
  pagination: {
11882
11277
  total: number;
@@ -11903,397 +11298,6 @@ export interface paths {
11903
11298
  patch?: never;
11904
11299
  trace?: never;
11905
11300
  };
11906
- '/api/applications/received/stats': {
11907
- parameters: {
11908
- query?: never;
11909
- header?: never;
11910
- path?: never;
11911
- cookie?: never;
11912
- };
11913
- /**
11914
- * Get received application statistics
11915
- * @description Get statistics for applications received by coordinator
11916
- */
11917
- get: {
11918
- parameters: {
11919
- query?: never;
11920
- header?: never;
11921
- path?: never;
11922
- cookie?: never;
11923
- };
11924
- requestBody?: never;
11925
- responses: {
11926
- /** @description Application statistics response (role-dependent structure) */
11927
- 200: {
11928
- headers: {
11929
- [name: string]: unknown;
11930
- };
11931
- content: {
11932
- 'application/json': {
11933
- /** @description Application statistics for applicants */
11934
- data: {
11935
- /** @description Application counts by status from applicant perspective */
11936
- byStatus: {
11937
- /** @description Non-negative integer (0 or greater) */
11938
- draft: number;
11939
- /** @description Non-negative integer (0 or greater) */
11940
- submitted: number;
11941
- /** @description Non-negative integer (0 or greater) */
11942
- approved: number;
11943
- /** @description Non-negative integer (0 or greater) */
11944
- rejected: number;
11945
- /** @description Non-negative integer (0 or greater) */
11946
- cancelled: number;
11947
- };
11948
- /** @description Application total counts for applicant */
11949
- totals: {
11950
- /** @description Non-negative integer (0 or greater) */
11951
- all: number;
11952
- /** @description Non-negative integer (0 or greater) */
11953
- active: number;
11954
- };
11955
- };
11956
- /** @description Metadata about the statistics query and response */
11957
- metadata: {
11958
- /** @description Role context for the statistics query */
11959
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
11960
- /**
11961
- * Format: uuid
11962
- * @description UUID version 4 identifier
11963
- */
11964
- accountId?: string;
11965
- /**
11966
- * Format: uuid
11967
- * @description UUID version 4 identifier
11968
- */
11969
- userId?: string;
11970
- /**
11971
- * Format: date-time
11972
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
11973
- */
11974
- queriedAt: string;
11975
- /** @description Whether the result was served from cache */
11976
- cached?: boolean;
11977
- /**
11978
- * Format: date-time
11979
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
11980
- */
11981
- cacheExpiresAt?: string;
11982
- };
11983
- } | {
11984
- /** @description Application statistics for coordinators */
11985
- data: {
11986
- /** @description Application counts by status from coordinator perspective */
11987
- byStatus: {
11988
- /** @description Non-negative integer (0 or greater) */
11989
- received: number;
11990
- /** @description Non-negative integer (0 or greater) */
11991
- pending_review: number;
11992
- /** @description Non-negative integer (0 or greater) */
11993
- approved: number;
11994
- /** @description Non-negative integer (0 or greater) */
11995
- rejected: number;
11996
- };
11997
- /** @description Application total counts for coordinator */
11998
- totals: {
11999
- /** @description Non-negative integer (0 or greater) */
12000
- all: number;
12001
- /** @description Non-negative integer (0 or greater) */
12002
- active: number;
12003
- /** @description Non-negative integer (0 or greater) */
12004
- needsReview?: number;
12005
- };
12006
- };
12007
- /** @description Metadata about the statistics query and response */
12008
- metadata: {
12009
- /** @description Role context for the statistics query */
12010
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
12011
- /**
12012
- * Format: uuid
12013
- * @description UUID version 4 identifier
12014
- */
12015
- accountId?: string;
12016
- /**
12017
- * Format: uuid
12018
- * @description UUID version 4 identifier
12019
- */
12020
- userId?: string;
12021
- /**
12022
- * Format: date-time
12023
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12024
- */
12025
- queriedAt: string;
12026
- /** @description Whether the result was served from cache */
12027
- cached?: boolean;
12028
- /**
12029
- * Format: date-time
12030
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12031
- */
12032
- cacheExpiresAt?: string;
12033
- };
12034
- } | {
12035
- /** @description Application statistics for assistants */
12036
- data: {
12037
- /** @description Application counts by status from assistant perspective */
12038
- byStatus: {
12039
- /** @description Non-negative integer (0 or greater) */
12040
- draft: number;
12041
- /** @description Non-negative integer (0 or greater) */
12042
- submitted: number;
12043
- /** @description Non-negative integer (0 or greater) */
12044
- approved: number;
12045
- /** @description Non-negative integer (0 or greater) */
12046
- rejected: number;
12047
- /** @description Non-negative integer (0 or greater) */
12048
- cancelled: number;
12049
- };
12050
- /** @description Application total counts for assistant with focus on status lifecycle */
12051
- totals: {
12052
- /** @description Non-negative integer (0 or greater) */
12053
- all: number;
12054
- /** @description Non-negative integer (0 or greater) */
12055
- draft: number;
12056
- /** @description Non-negative integer (0 or greater) */
12057
- waitingResponse: number;
12058
- /** @description Non-negative integer (0 or greater) */
12059
- approved: number;
12060
- /** @description Non-negative integer (0 or greater) */
12061
- rejected: number;
12062
- /** @description Non-negative integer (0 or greater) */
12063
- active?: number;
12064
- /** @description Non-negative integer (0 or greater) */
12065
- needsAction?: number;
12066
- /** @description Non-negative integer (0 or greater) */
12067
- inProgress?: number;
12068
- };
12069
- alerts?: {
12070
- type: 'info' | 'warning' | 'error' | 'action_required';
12071
- severity: 'low' | 'medium' | 'high';
12072
- /** @description Non-negative integer (0 or greater) */
12073
- count: number;
12074
- message: string;
12075
- status: string;
12076
- }[];
12077
- };
12078
- /** @description Metadata about the statistics query and response */
12079
- metadata: {
12080
- /** @description Role context for the statistics query */
12081
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
12082
- /**
12083
- * Format: uuid
12084
- * @description UUID version 4 identifier
12085
- */
12086
- accountId?: string;
12087
- /**
12088
- * Format: uuid
12089
- * @description UUID version 4 identifier
12090
- */
12091
- userId?: string;
12092
- /**
12093
- * Format: date-time
12094
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12095
- */
12096
- queriedAt: string;
12097
- /** @description Whether the result was served from cache */
12098
- cached?: boolean;
12099
- /**
12100
- * Format: date-time
12101
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12102
- */
12103
- cacheExpiresAt?: string;
12104
- };
12105
- } | {
12106
- /** @description Application statistics for teamleads */
12107
- data: {
12108
- /** @description Application counts by status from teamlead perspective */
12109
- byStatus: {
12110
- /** @description Non-negative integer (0 or greater) */
12111
- submitted: number;
12112
- /** @description Non-negative integer (0 or greater) */
12113
- approved: number;
12114
- /** @description Non-negative integer (0 or greater) */
12115
- rejected: number;
12116
- /** @description Non-negative integer (0 or greater) */
12117
- cancelled: number;
12118
- };
12119
- /** @description Application total counts for teamlead with focus on review pipeline */
12120
- totals: {
12121
- /** @description Non-negative integer (0 or greater) */
12122
- all: number;
12123
- /** @description Non-negative integer (0 or greater) */
12124
- newApplications: number;
12125
- /** @description Non-negative integer (0 or greater) */
12126
- pendingReview: number;
12127
- /** @description Non-negative integer (0 or greater) */
12128
- approved: number;
12129
- /** @description Non-negative integer (0 or greater) */
12130
- rejected: number;
12131
- /** @description Non-negative integer (0 or greater) */
12132
- active?: number;
12133
- /** @description Non-negative integer (0 or greater) */
12134
- needsAction?: number;
12135
- /** @description Non-negative integer (0 or greater) */
12136
- inProgress?: number;
12137
- };
12138
- alerts?: {
12139
- type: 'info' | 'warning' | 'error' | 'action_required';
12140
- severity: 'low' | 'medium' | 'high';
12141
- /** @description Non-negative integer (0 or greater) */
12142
- count: number;
12143
- message: string;
12144
- status: string;
12145
- }[];
12146
- };
12147
- /** @description Metadata about the statistics query and response */
12148
- metadata: {
12149
- /** @description Role context for the statistics query */
12150
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
12151
- /**
12152
- * Format: uuid
12153
- * @description UUID version 4 identifier
12154
- */
12155
- accountId?: string;
12156
- /**
12157
- * Format: uuid
12158
- * @description UUID version 4 identifier
12159
- */
12160
- userId?: string;
12161
- /**
12162
- * Format: date-time
12163
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12164
- */
12165
- queriedAt: string;
12166
- /** @description Whether the result was served from cache */
12167
- cached?: boolean;
12168
- /**
12169
- * Format: date-time
12170
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12171
- */
12172
- cacheExpiresAt?: string;
12173
- };
12174
- };
12175
- };
12176
- };
12177
- };
12178
- };
12179
- put?: never;
12180
- post?: never;
12181
- delete?: never;
12182
- options?: never;
12183
- head?: never;
12184
- patch?: never;
12185
- trace?: never;
12186
- };
12187
- '/api/applications/sent/stats': {
12188
- parameters: {
12189
- query?: never;
12190
- header?: never;
12191
- path?: never;
12192
- cookie?: never;
12193
- };
12194
- /**
12195
- * Get sent application statistics
12196
- * @description Get statistics for applications sent by the current user
12197
- */
12198
- get: {
12199
- parameters: {
12200
- query?: never;
12201
- header?: never;
12202
- path?: never;
12203
- cookie?: never;
12204
- };
12205
- requestBody?: never;
12206
- responses: {
12207
- /** @description Standard statistics response wrapper */
12208
- 200: {
12209
- headers: {
12210
- [name: string]: unknown;
12211
- };
12212
- content: {
12213
- 'application/json': {
12214
- /** @description Application statistics for assistants */
12215
- data: {
12216
- /** @description Application counts by status from assistant perspective */
12217
- byStatus: {
12218
- /** @description Non-negative integer (0 or greater) */
12219
- draft: number;
12220
- /** @description Non-negative integer (0 or greater) */
12221
- submitted: number;
12222
- /** @description Non-negative integer (0 or greater) */
12223
- approved: number;
12224
- /** @description Non-negative integer (0 or greater) */
12225
- rejected: number;
12226
- /** @description Non-negative integer (0 or greater) */
12227
- cancelled: number;
12228
- };
12229
- /** @description Application total counts for assistant with focus on status lifecycle */
12230
- totals: {
12231
- /** @description Non-negative integer (0 or greater) */
12232
- all: number;
12233
- /** @description Non-negative integer (0 or greater) */
12234
- draft: number;
12235
- /** @description Non-negative integer (0 or greater) */
12236
- waitingResponse: number;
12237
- /** @description Non-negative integer (0 or greater) */
12238
- approved: number;
12239
- /** @description Non-negative integer (0 or greater) */
12240
- rejected: number;
12241
- /** @description Non-negative integer (0 or greater) */
12242
- active?: number;
12243
- /** @description Non-negative integer (0 or greater) */
12244
- needsAction?: number;
12245
- /** @description Non-negative integer (0 or greater) */
12246
- inProgress?: number;
12247
- };
12248
- alerts?: {
12249
- type: 'info' | 'warning' | 'error' | 'action_required';
12250
- severity: 'low' | 'medium' | 'high';
12251
- /** @description Non-negative integer (0 or greater) */
12252
- count: number;
12253
- message: string;
12254
- status: string;
12255
- }[];
12256
- };
12257
- /** @description Metadata about the statistics query and response */
12258
- metadata: {
12259
- /** @description Role context for the statistics query */
12260
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
12261
- /**
12262
- * Format: uuid
12263
- * @description UUID version 4 identifier
12264
- */
12265
- accountId?: string;
12266
- /**
12267
- * Format: uuid
12268
- * @description UUID version 4 identifier
12269
- */
12270
- userId?: string;
12271
- /**
12272
- * Format: date-time
12273
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12274
- */
12275
- queriedAt: string;
12276
- /** @description Whether the result was served from cache */
12277
- cached?: boolean;
12278
- /**
12279
- * Format: date-time
12280
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
12281
- */
12282
- cacheExpiresAt?: string;
12283
- };
12284
- };
12285
- };
12286
- };
12287
- };
12288
- };
12289
- put?: never;
12290
- post?: never;
12291
- delete?: never;
12292
- options?: never;
12293
- head?: never;
12294
- patch?: never;
12295
- trace?: never;
12296
- };
12297
11301
  '/api/applications/{applicationId}': {
12298
11302
  parameters: {
12299
11303
  query?: never;
@@ -12346,7 +11350,7 @@ export interface paths {
12346
11350
  /** @description Reference to the account that owns this application */
12347
11351
  account_id?: string | null;
12348
11352
  /** @description Current status of the application in the workflow */
12349
- status: 'draft' | 'submitted' | 'approved' | 'rejected' | 'cancelled';
11353
+ status: 'draft' | 'submitted' | 'approved' | 'rejected' | 'cancelled' | 'contracted';
12350
11354
  /** @description Lifecycle status for data management and GDPR compliance */
12351
11355
  lifecycle_status: 'operational' | 'deleted' | 'archived';
12352
11356
  cover_letter?: string | null;
@@ -12465,7 +11469,7 @@ export interface paths {
12465
11469
  /** @description Reference to the account that owns this application */
12466
11470
  account_id?: string | null;
12467
11471
  /** @description Current status of the application in the workflow */
12468
- status: 'draft' | 'submitted' | 'approved' | 'rejected' | 'cancelled';
11472
+ status: 'draft' | 'submitted' | 'approved' | 'rejected' | 'cancelled' | 'contracted';
12469
11473
  /** @description Lifecycle status for data management and GDPR compliance */
12470
11474
  lifecycle_status: 'operational' | 'deleted' | 'archived';
12471
11475
  cover_letter?: string | null;
@@ -12637,6 +11641,7 @@ export interface paths {
12637
11641
  approved_at?: string | null;
12638
11642
  rejected_at?: string | null;
12639
11643
  cancelled_at?: string | null;
11644
+ contracted_at?: string | null;
12640
11645
  submitted_by?: string | null;
12641
11646
  submitted_by_name?: string | null;
12642
11647
  approved_by?: string | null;
@@ -12675,6 +11680,7 @@ export interface paths {
12675
11680
  coordinator_exists?: boolean | null;
12676
11681
  can_reapply?: boolean | null;
12677
11682
  has_contract?: boolean | null;
11683
+ contract_id?: string | null;
12678
11684
  attachments?: {
12679
11685
  /** Format: uuid */
12680
11686
  id: string;
@@ -12781,7 +11787,7 @@ export interface paths {
12781
11787
  /** @description Reference to the account that owns this application */
12782
11788
  account_id?: string | null;
12783
11789
  /** @description Current status of the application in the workflow */
12784
- status: 'draft' | 'submitted' | 'approved' | 'rejected' | 'cancelled';
11790
+ status: 'draft' | 'submitted' | 'approved' | 'rejected' | 'cancelled' | 'contracted';
12785
11791
  /** @description Lifecycle status for data management and GDPR compliance */
12786
11792
  lifecycle_status: 'operational' | 'deleted' | 'archived';
12787
11793
  cover_letter?: string | null;
@@ -12923,6 +11929,7 @@ export interface paths {
12923
11929
  approved_at?: string | null;
12924
11930
  rejected_at?: string | null;
12925
11931
  cancelled_at?: string | null;
11932
+ contracted_at?: string | null;
12926
11933
  submitted_by?: string | null;
12927
11934
  submitted_by_name?: string | null;
12928
11935
  approved_by?: string | null;
@@ -12961,6 +11968,7 @@ export interface paths {
12961
11968
  coordinator_exists?: boolean | null;
12962
11969
  can_reapply?: boolean | null;
12963
11970
  has_contract?: boolean | null;
11971
+ contract_id?: string | null;
12964
11972
  attachments?: {
12965
11973
  /** Format: uuid */
12966
11974
  id: string;
@@ -13067,6 +12075,7 @@ export interface paths {
13067
12075
  approved_at?: string | null;
13068
12076
  rejected_at?: string | null;
13069
12077
  cancelled_at?: string | null;
12078
+ contracted_at?: string | null;
13070
12079
  submitted_by?: string | null;
13071
12080
  submitted_by_name?: string | null;
13072
12081
  approved_by?: string | null;
@@ -13105,6 +12114,7 @@ export interface paths {
13105
12114
  coordinator_exists?: boolean | null;
13106
12115
  can_reapply?: boolean | null;
13107
12116
  has_contract?: boolean | null;
12117
+ contract_id?: string | null;
13108
12118
  attachments?: {
13109
12119
  /** Format: uuid */
13110
12120
  id: string;
@@ -13211,6 +12221,7 @@ export interface paths {
13211
12221
  approved_at?: string | null;
13212
12222
  rejected_at?: string | null;
13213
12223
  cancelled_at?: string | null;
12224
+ contracted_at?: string | null;
13214
12225
  submitted_by?: string | null;
13215
12226
  submitted_by_name?: string | null;
13216
12227
  approved_by?: string | null;
@@ -13249,6 +12260,7 @@ export interface paths {
13249
12260
  coordinator_exists?: boolean | null;
13250
12261
  can_reapply?: boolean | null;
13251
12262
  has_contract?: boolean | null;
12263
+ contract_id?: string | null;
13252
12264
  attachments?: {
13253
12265
  /** Format: uuid */
13254
12266
  id: string;
@@ -13355,6 +12367,7 @@ export interface paths {
13355
12367
  approved_at?: string | null;
13356
12368
  rejected_at?: string | null;
13357
12369
  cancelled_at?: string | null;
12370
+ contracted_at?: string | null;
13358
12371
  submitted_by?: string | null;
13359
12372
  submitted_by_name?: string | null;
13360
12373
  approved_by?: string | null;
@@ -13393,6 +12406,7 @@ export interface paths {
13393
12406
  coordinator_exists?: boolean | null;
13394
12407
  can_reapply?: boolean | null;
13395
12408
  has_contract?: boolean | null;
12409
+ contract_id?: string | null;
13396
12410
  attachments?: {
13397
12411
  /** Format: uuid */
13398
12412
  id: string;
@@ -13499,6 +12513,7 @@ export interface paths {
13499
12513
  approved_at?: string | null;
13500
12514
  rejected_at?: string | null;
13501
12515
  cancelled_at?: string | null;
12516
+ contracted_at?: string | null;
13502
12517
  submitted_by?: string | null;
13503
12518
  submitted_by_name?: string | null;
13504
12519
  approved_by?: string | null;
@@ -13537,6 +12552,7 @@ export interface paths {
13537
12552
  coordinator_exists?: boolean | null;
13538
12553
  can_reapply?: boolean | null;
13539
12554
  has_contract?: boolean | null;
12555
+ contract_id?: string | null;
13540
12556
  attachments?: {
13541
12557
  /** Format: uuid */
13542
12558
  id: string;
@@ -13641,6 +12657,7 @@ export interface paths {
13641
12657
  employer_email?: string | null;
13642
12658
  can_reapply?: boolean | null;
13643
12659
  has_contract?: boolean | null;
12660
+ contract_id?: string | null;
13644
12661
  }[];
13645
12662
  pagination: {
13646
12663
  total: number;
@@ -13739,6 +12756,7 @@ export interface paths {
13739
12756
  approved_at?: string | null;
13740
12757
  rejected_at?: string | null;
13741
12758
  cancelled_at?: string | null;
12759
+ contracted_at?: string | null;
13742
12760
  submitted_by?: string | null;
13743
12761
  submitted_by_name?: string | null;
13744
12762
  approved_by?: string | null;
@@ -13777,6 +12795,7 @@ export interface paths {
13777
12795
  coordinator_exists?: boolean | null;
13778
12796
  can_reapply?: boolean | null;
13779
12797
  has_contract?: boolean | null;
12798
+ contract_id?: string | null;
13780
12799
  attachments?: {
13781
12800
  /** Format: uuid */
13782
12801
  id: string;
@@ -13889,6 +12908,7 @@ export interface paths {
13889
12908
  approved_at?: string | null;
13890
12909
  rejected_at?: string | null;
13891
12910
  cancelled_at?: string | null;
12911
+ contracted_at?: string | null;
13892
12912
  submitted_by?: string | null;
13893
12913
  submitted_by_name?: string | null;
13894
12914
  approved_by?: string | null;
@@ -13927,6 +12947,7 @@ export interface paths {
13927
12947
  coordinator_exists?: boolean | null;
13928
12948
  can_reapply?: boolean | null;
13929
12949
  has_contract?: boolean | null;
12950
+ contract_id?: string | null;
13930
12951
  attachments?: {
13931
12952
  /** Format: uuid */
13932
12953
  id: string;
@@ -14956,7 +13977,7 @@ export interface paths {
14956
13977
  * InquiryStatus
14957
13978
  * @description Business status of an inquiry in the workflow
14958
13979
  */
14959
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
13980
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
14960
13981
  /**
14961
13982
  * InquiryLifecycleStatus
14962
13983
  * @description Data lifecycle status for GDPR compliance
@@ -14993,6 +14014,7 @@ export interface paths {
14993
14014
  declined_at?: string | null;
14994
14015
  cancelled_message?: string | null;
14995
14016
  cancelled_at?: string | null;
14017
+ contracted_at?: string | null;
14996
14018
  expires_at?: string | null;
14997
14019
  inquiry_number?: number | null;
14998
14020
  archived_by_inquirer?: boolean | null;
@@ -15106,6 +14128,8 @@ export interface paths {
15106
14128
  has_job_reference?: boolean | null;
15107
14129
  has_response?: boolean | null;
15108
14130
  is_pending_response?: boolean | null;
14131
+ has_contract?: boolean | null;
14132
+ contract_id?: string | null;
15109
14133
  attachments?: {
15110
14134
  /** Format: uuid */
15111
14135
  id: string;
@@ -15230,7 +14254,7 @@ export interface paths {
15230
14254
  * InquiryStatus
15231
14255
  * @description Business status of an inquiry in the workflow
15232
14256
  */
15233
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
14257
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
15234
14258
  /**
15235
14259
  * InquiryLifecycleStatus
15236
14260
  * @description Data lifecycle status for GDPR compliance
@@ -15267,6 +14291,7 @@ export interface paths {
15267
14291
  declined_at?: string | null;
15268
14292
  cancelled_message?: string | null;
15269
14293
  cancelled_at?: string | null;
14294
+ contracted_at?: string | null;
15270
14295
  expires_at?: string | null;
15271
14296
  inquiry_number?: number | null;
15272
14297
  archived_by_inquirer?: boolean | null;
@@ -15380,6 +14405,8 @@ export interface paths {
15380
14405
  has_job_reference?: boolean | null;
15381
14406
  has_response?: boolean | null;
15382
14407
  is_pending_response?: boolean | null;
14408
+ has_contract?: boolean | null;
14409
+ contract_id?: string | null;
15383
14410
  attachments?: {
15384
14411
  /** Format: uuid */
15385
14412
  id: string;
@@ -15496,7 +14523,7 @@ export interface paths {
15496
14523
  * InquiryStatus
15497
14524
  * @description Business status of an inquiry in the workflow
15498
14525
  */
15499
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
14526
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
15500
14527
  /**
15501
14528
  * InquiryLifecycleStatus
15502
14529
  * @description Data lifecycle status for GDPR compliance
@@ -15533,6 +14560,7 @@ export interface paths {
15533
14560
  declined_at?: string | null;
15534
14561
  cancelled_message?: string | null;
15535
14562
  cancelled_at?: string | null;
14563
+ contracted_at?: string | null;
15536
14564
  expires_at?: string | null;
15537
14565
  inquiry_number?: number | null;
15538
14566
  archived_by_inquirer?: boolean | null;
@@ -15646,6 +14674,8 @@ export interface paths {
15646
14674
  has_job_reference?: boolean | null;
15647
14675
  has_response?: boolean | null;
15648
14676
  is_pending_response?: boolean | null;
14677
+ has_contract?: boolean | null;
14678
+ contract_id?: string | null;
15649
14679
  attachments?: {
15650
14680
  /** Format: uuid */
15651
14681
  id: string;
@@ -15717,7 +14747,7 @@ export interface paths {
15717
14747
  * InquiryStatus
15718
14748
  * @description Business status of an inquiry in the workflow
15719
14749
  */
15720
- status?: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
14750
+ status?: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
15721
14751
  accepted_message?: string | null;
15722
14752
  accepted_at?: string | null;
15723
14753
  declined_message?: string | null;
@@ -15786,7 +14816,7 @@ export interface paths {
15786
14816
  * InquiryStatus
15787
14817
  * @description Business status of an inquiry in the workflow
15788
14818
  */
15789
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
14819
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
15790
14820
  /**
15791
14821
  * InquiryLifecycleStatus
15792
14822
  * @description Data lifecycle status for GDPR compliance
@@ -15823,6 +14853,7 @@ export interface paths {
15823
14853
  declined_at?: string | null;
15824
14854
  cancelled_message?: string | null;
15825
14855
  cancelled_at?: string | null;
14856
+ contracted_at?: string | null;
15826
14857
  expires_at?: string | null;
15827
14858
  inquiry_number?: number | null;
15828
14859
  archived_by_inquirer?: boolean | null;
@@ -15936,6 +14967,8 @@ export interface paths {
15936
14967
  has_job_reference?: boolean | null;
15937
14968
  has_response?: boolean | null;
15938
14969
  is_pending_response?: boolean | null;
14970
+ has_contract?: boolean | null;
14971
+ contract_id?: string | null;
15939
14972
  attachments?: {
15940
14973
  /** Format: uuid */
15941
14974
  id: string;
@@ -16086,7 +15119,7 @@ export interface paths {
16086
15119
  * InquiryStatus
16087
15120
  * @description Business status of an inquiry in the workflow
16088
15121
  */
16089
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
15122
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
16090
15123
  /**
16091
15124
  * InquiryLifecycleStatus
16092
15125
  * @description Data lifecycle status for GDPR compliance
@@ -16123,6 +15156,7 @@ export interface paths {
16123
15156
  declined_at?: string | null;
16124
15157
  cancelled_message?: string | null;
16125
15158
  cancelled_at?: string | null;
15159
+ contracted_at?: string | null;
16126
15160
  expires_at?: string | null;
16127
15161
  inquiry_number?: number | null;
16128
15162
  archived_by_inquirer?: boolean | null;
@@ -16236,6 +15270,8 @@ export interface paths {
16236
15270
  has_job_reference?: boolean | null;
16237
15271
  has_response?: boolean | null;
16238
15272
  is_pending_response?: boolean | null;
15273
+ has_contract?: boolean | null;
15274
+ contract_id?: string | null;
16239
15275
  attachments?: {
16240
15276
  /** Format: uuid */
16241
15277
  id: string;
@@ -16324,7 +15360,7 @@ export interface paths {
16324
15360
  * InquiryStatus
16325
15361
  * @description Business status of an inquiry in the workflow
16326
15362
  */
16327
- status?: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
15363
+ status?: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
16328
15364
  accepted_message?: string | null;
16329
15365
  accepted_at?: string | null;
16330
15366
  declined_message?: string | null;
@@ -16393,7 +15429,7 @@ export interface paths {
16393
15429
  * InquiryStatus
16394
15430
  * @description Business status of an inquiry in the workflow
16395
15431
  */
16396
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
15432
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
16397
15433
  /**
16398
15434
  * InquiryLifecycleStatus
16399
15435
  * @description Data lifecycle status for GDPR compliance
@@ -16430,6 +15466,7 @@ export interface paths {
16430
15466
  declined_at?: string | null;
16431
15467
  cancelled_message?: string | null;
16432
15468
  cancelled_at?: string | null;
15469
+ contracted_at?: string | null;
16433
15470
  expires_at?: string | null;
16434
15471
  inquiry_number?: number | null;
16435
15472
  archived_by_inquirer?: boolean | null;
@@ -16543,6 +15580,8 @@ export interface paths {
16543
15580
  has_job_reference?: boolean | null;
16544
15581
  has_response?: boolean | null;
16545
15582
  is_pending_response?: boolean | null;
15583
+ has_contract?: boolean | null;
15584
+ contract_id?: string | null;
16546
15585
  attachments?: {
16547
15586
  /** Format: uuid */
16548
15587
  id: string;
@@ -16679,7 +15718,7 @@ export interface paths {
16679
15718
  * InquiryStatus
16680
15719
  * @description Business status of an inquiry in the workflow
16681
15720
  */
16682
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
15721
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
16683
15722
  /**
16684
15723
  * InquiryLifecycleStatus
16685
15724
  * @description Data lifecycle status for GDPR compliance
@@ -16716,6 +15755,7 @@ export interface paths {
16716
15755
  declined_at?: string | null;
16717
15756
  cancelled_message?: string | null;
16718
15757
  cancelled_at?: string | null;
15758
+ contracted_at?: string | null;
16719
15759
  expires_at?: string | null;
16720
15760
  inquiry_number?: number | null;
16721
15761
  archived_by_inquirer?: boolean | null;
@@ -16829,6 +15869,8 @@ export interface paths {
16829
15869
  has_job_reference?: boolean | null;
16830
15870
  has_response?: boolean | null;
16831
15871
  is_pending_response?: boolean | null;
15872
+ has_contract?: boolean | null;
15873
+ contract_id?: string | null;
16832
15874
  attachments?: {
16833
15875
  /** Format: uuid */
16834
15876
  id: string;
@@ -16959,7 +16001,7 @@ export interface paths {
16959
16001
  * InquiryStatus
16960
16002
  * @description Business status of an inquiry in the workflow
16961
16003
  */
16962
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
16004
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
16963
16005
  /**
16964
16006
  * InquiryLifecycleStatus
16965
16007
  * @description Data lifecycle status for GDPR compliance
@@ -16996,6 +16038,7 @@ export interface paths {
16996
16038
  declined_at?: string | null;
16997
16039
  cancelled_message?: string | null;
16998
16040
  cancelled_at?: string | null;
16041
+ contracted_at?: string | null;
16999
16042
  expires_at?: string | null;
17000
16043
  inquiry_number?: number | null;
17001
16044
  archived_by_inquirer?: boolean | null;
@@ -17109,6 +16152,8 @@ export interface paths {
17109
16152
  has_job_reference?: boolean | null;
17110
16153
  has_response?: boolean | null;
17111
16154
  is_pending_response?: boolean | null;
16155
+ has_contract?: boolean | null;
16156
+ contract_id?: string | null;
17112
16157
  attachments?: {
17113
16158
  /** Format: uuid */
17114
16159
  id: string;
@@ -17239,7 +16284,7 @@ export interface paths {
17239
16284
  * InquiryStatus
17240
16285
  * @description Business status of an inquiry in the workflow
17241
16286
  */
17242
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
16287
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
17243
16288
  /**
17244
16289
  * InquiryLifecycleStatus
17245
16290
  * @description Data lifecycle status for GDPR compliance
@@ -17276,6 +16321,7 @@ export interface paths {
17276
16321
  declined_at?: string | null;
17277
16322
  cancelled_message?: string | null;
17278
16323
  cancelled_at?: string | null;
16324
+ contracted_at?: string | null;
17279
16325
  expires_at?: string | null;
17280
16326
  inquiry_number?: number | null;
17281
16327
  archived_by_inquirer?: boolean | null;
@@ -17389,6 +16435,8 @@ export interface paths {
17389
16435
  has_job_reference?: boolean | null;
17390
16436
  has_response?: boolean | null;
17391
16437
  is_pending_response?: boolean | null;
16438
+ has_contract?: boolean | null;
16439
+ contract_id?: string | null;
17392
16440
  attachments?: {
17393
16441
  /** Format: uuid */
17394
16442
  id: string;
@@ -17513,7 +16561,7 @@ export interface paths {
17513
16561
  * InquiryStatus
17514
16562
  * @description Business status of an inquiry in the workflow
17515
16563
  */
17516
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
16564
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
17517
16565
  /**
17518
16566
  * InquiryLifecycleStatus
17519
16567
  * @description Data lifecycle status for GDPR compliance
@@ -17550,6 +16598,7 @@ export interface paths {
17550
16598
  declined_at?: string | null;
17551
16599
  cancelled_message?: string | null;
17552
16600
  cancelled_at?: string | null;
16601
+ contracted_at?: string | null;
17553
16602
  expires_at?: string | null;
17554
16603
  inquiry_number?: number | null;
17555
16604
  archived_by_inquirer?: boolean | null;
@@ -17663,6 +16712,8 @@ export interface paths {
17663
16712
  has_job_reference?: boolean | null;
17664
16713
  has_response?: boolean | null;
17665
16714
  is_pending_response?: boolean | null;
16715
+ has_contract?: boolean | null;
16716
+ contract_id?: string | null;
17666
16717
  attachments?: {
17667
16718
  /** Format: uuid */
17668
16719
  id: string;
@@ -17787,7 +16838,7 @@ export interface paths {
17787
16838
  * InquiryStatus
17788
16839
  * @description Business status of an inquiry in the workflow
17789
16840
  */
17790
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
16841
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
17791
16842
  /**
17792
16843
  * InquiryLifecycleStatus
17793
16844
  * @description Data lifecycle status for GDPR compliance
@@ -17824,6 +16875,7 @@ export interface paths {
17824
16875
  declined_at?: string | null;
17825
16876
  cancelled_message?: string | null;
17826
16877
  cancelled_at?: string | null;
16878
+ contracted_at?: string | null;
17827
16879
  expires_at?: string | null;
17828
16880
  inquiry_number?: number | null;
17829
16881
  archived_by_inquirer?: boolean | null;
@@ -17937,6 +16989,8 @@ export interface paths {
17937
16989
  has_job_reference?: boolean | null;
17938
16990
  has_response?: boolean | null;
17939
16991
  is_pending_response?: boolean | null;
16992
+ has_contract?: boolean | null;
16993
+ contract_id?: string | null;
17940
16994
  attachments?: {
17941
16995
  /** Format: uuid */
17942
16996
  id: string;
@@ -18061,7 +17115,7 @@ export interface paths {
18061
17115
  * InquiryStatus
18062
17116
  * @description Business status of an inquiry in the workflow
18063
17117
  */
18064
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
17118
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
18065
17119
  /**
18066
17120
  * InquiryLifecycleStatus
18067
17121
  * @description Data lifecycle status for GDPR compliance
@@ -18098,6 +17152,7 @@ export interface paths {
18098
17152
  declined_at?: string | null;
18099
17153
  cancelled_message?: string | null;
18100
17154
  cancelled_at?: string | null;
17155
+ contracted_at?: string | null;
18101
17156
  expires_at?: string | null;
18102
17157
  inquiry_number?: number | null;
18103
17158
  archived_by_inquirer?: boolean | null;
@@ -18211,6 +17266,8 @@ export interface paths {
18211
17266
  has_job_reference?: boolean | null;
18212
17267
  has_response?: boolean | null;
18213
17268
  is_pending_response?: boolean | null;
17269
+ has_contract?: boolean | null;
17270
+ contract_id?: string | null;
18214
17271
  attachments?: {
18215
17272
  /** Format: uuid */
18216
17273
  id: string;
@@ -18335,7 +17392,7 @@ export interface paths {
18335
17392
  * InquiryStatus
18336
17393
  * @description Business status of an inquiry in the workflow
18337
17394
  */
18338
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
17395
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
18339
17396
  /**
18340
17397
  * InquiryLifecycleStatus
18341
17398
  * @description Data lifecycle status for GDPR compliance
@@ -18372,6 +17429,7 @@ export interface paths {
18372
17429
  declined_at?: string | null;
18373
17430
  cancelled_message?: string | null;
18374
17431
  cancelled_at?: string | null;
17432
+ contracted_at?: string | null;
18375
17433
  expires_at?: string | null;
18376
17434
  inquiry_number?: number | null;
18377
17435
  archived_by_inquirer?: boolean | null;
@@ -18485,6 +17543,8 @@ export interface paths {
18485
17543
  has_job_reference?: boolean | null;
18486
17544
  has_response?: boolean | null;
18487
17545
  is_pending_response?: boolean | null;
17546
+ has_contract?: boolean | null;
17547
+ contract_id?: string | null;
18488
17548
  attachments?: {
18489
17549
  /** Format: uuid */
18490
17550
  id: string;
@@ -18532,410 +17592,6 @@ export interface paths {
18532
17592
  patch?: never;
18533
17593
  trace?: never;
18534
17594
  };
18535
- '/api/inquiries/sent/stats': {
18536
- parameters: {
18537
- query?: never;
18538
- header?: never;
18539
- path?: never;
18540
- cookie?: never;
18541
- };
18542
- /**
18543
- * Get sent inquiry statistics
18544
- * @description Get statistics for inquiries sent by coordinators
18545
- */
18546
- get: {
18547
- parameters: {
18548
- query?: never;
18549
- header?: never;
18550
- path?: never;
18551
- cookie?: never;
18552
- };
18553
- requestBody?: never;
18554
- responses: {
18555
- /** @description Standard statistics response wrapper */
18556
- 200: {
18557
- headers: {
18558
- [name: string]: unknown;
18559
- };
18560
- content: {
18561
- 'application/json': {
18562
- /** @description Inquiry statistics for coordinators */
18563
- data: {
18564
- /** @description Inquiry counts by status from coordinator perspective */
18565
- byStatus: {
18566
- /** @description Non-negative integer (0 or greater) */
18567
- draft: number;
18568
- /** @description Non-negative integer (0 or greater) */
18569
- submitted: number;
18570
- /** @description Non-negative integer (0 or greater) */
18571
- accepted: number;
18572
- /** @description Non-negative integer (0 or greater) */
18573
- declined: number;
18574
- /** @description Non-negative integer (0 or greater) */
18575
- cancelled: number;
18576
- /** @description Non-negative integer (0 or greater) */
18577
- expired?: number;
18578
- };
18579
- /** @description Inquiry total counts for coordinator */
18580
- totals: {
18581
- /** @description Non-negative integer (0 or greater) */
18582
- all: number;
18583
- /** @description Non-negative integer (0 or greater) */
18584
- active: number;
18585
- /** @description Non-negative integer (0 or greater) */
18586
- needsAction?: number;
18587
- /** @description Non-negative integer (0 or greater) */
18588
- inProgress?: number;
18589
- };
18590
- alerts?: {
18591
- type: 'info' | 'warning' | 'error' | 'action_required';
18592
- severity: 'low' | 'medium' | 'high';
18593
- /** @description Non-negative integer (0 or greater) */
18594
- count: number;
18595
- message: string;
18596
- status: string;
18597
- }[];
18598
- };
18599
- /** @description Metadata about the statistics query and response */
18600
- metadata: {
18601
- /** @description Role context for the statistics query */
18602
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
18603
- /**
18604
- * Format: uuid
18605
- * @description UUID version 4 identifier
18606
- */
18607
- accountId?: string;
18608
- /**
18609
- * Format: uuid
18610
- * @description UUID version 4 identifier
18611
- */
18612
- userId?: string;
18613
- /**
18614
- * Format: date-time
18615
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18616
- */
18617
- queriedAt: string;
18618
- /** @description Whether the result was served from cache */
18619
- cached?: boolean;
18620
- /**
18621
- * Format: date-time
18622
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18623
- */
18624
- cacheExpiresAt?: string;
18625
- };
18626
- };
18627
- };
18628
- };
18629
- };
18630
- };
18631
- put?: never;
18632
- post?: never;
18633
- delete?: never;
18634
- options?: never;
18635
- head?: never;
18636
- patch?: never;
18637
- trace?: never;
18638
- };
18639
- '/api/inquiries/received/stats': {
18640
- parameters: {
18641
- query?: never;
18642
- header?: never;
18643
- path?: never;
18644
- cookie?: never;
18645
- };
18646
- /**
18647
- * Get received inquiry statistics
18648
- * @description Get statistics for inquiries received by assistants
18649
- */
18650
- get: {
18651
- parameters: {
18652
- query?: never;
18653
- header?: never;
18654
- path?: never;
18655
- cookie?: never;
18656
- };
18657
- requestBody?: never;
18658
- responses: {
18659
- /** @description Standard statistics response wrapper */
18660
- 200: {
18661
- headers: {
18662
- [name: string]: unknown;
18663
- };
18664
- content: {
18665
- 'application/json': {
18666
- /** @description Inquiry statistics for assistants */
18667
- data: {
18668
- /** @description Inquiry counts by status from assistant perspective */
18669
- byStatus: {
18670
- /** @description Non-negative integer (0 or greater) */
18671
- submitted?: number;
18672
- /** @description Non-negative integer (0 or greater) */
18673
- accepted?: number;
18674
- /** @description Non-negative integer (0 or greater) */
18675
- declined?: number;
18676
- };
18677
- /** @description Inquiry total counts for assistant */
18678
- totals: {
18679
- /** @description Non-negative integer (0 or greater) */
18680
- all: number;
18681
- /** @description Non-negative integer (0 or greater) */
18682
- active: number;
18683
- /** @description Non-negative integer (0 or greater) */
18684
- needsAction?: number;
18685
- /** @description Non-negative integer (0 or greater) */
18686
- inProgress?: number;
18687
- };
18688
- alerts?: {
18689
- type: 'info' | 'warning' | 'error' | 'action_required';
18690
- severity: 'low' | 'medium' | 'high';
18691
- /** @description Non-negative integer (0 or greater) */
18692
- count: number;
18693
- message: string;
18694
- status: string;
18695
- }[];
18696
- };
18697
- /** @description Metadata about the statistics query and response */
18698
- metadata: {
18699
- /** @description Role context for the statistics query */
18700
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
18701
- /**
18702
- * Format: uuid
18703
- * @description UUID version 4 identifier
18704
- */
18705
- accountId?: string;
18706
- /**
18707
- * Format: uuid
18708
- * @description UUID version 4 identifier
18709
- */
18710
- userId?: string;
18711
- /**
18712
- * Format: date-time
18713
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18714
- */
18715
- queriedAt: string;
18716
- /** @description Whether the result was served from cache */
18717
- cached?: boolean;
18718
- /**
18719
- * Format: date-time
18720
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18721
- */
18722
- cacheExpiresAt?: string;
18723
- };
18724
- };
18725
- };
18726
- };
18727
- };
18728
- };
18729
- put?: never;
18730
- post?: never;
18731
- delete?: never;
18732
- options?: never;
18733
- head?: never;
18734
- patch?: never;
18735
- trace?: never;
18736
- };
18737
- '/api/inquiries/teamlead/stats': {
18738
- parameters: {
18739
- query?: never;
18740
- header?: never;
18741
- path?: never;
18742
- cookie?: never;
18743
- };
18744
- /**
18745
- * Get inquiry statistics for team leaders
18746
- * @description Get statistics for inquiries sent by team leaders/coordinators
18747
- */
18748
- get: {
18749
- parameters: {
18750
- query?: never;
18751
- header?: never;
18752
- path?: never;
18753
- cookie?: never;
18754
- };
18755
- requestBody?: never;
18756
- responses: {
18757
- /** @description Standard statistics response wrapper */
18758
- 200: {
18759
- headers: {
18760
- [name: string]: unknown;
18761
- };
18762
- content: {
18763
- 'application/json': {
18764
- /** @description Inquiry statistics for coordinators */
18765
- data: {
18766
- /** @description Inquiry counts by status from coordinator perspective */
18767
- byStatus: {
18768
- /** @description Non-negative integer (0 or greater) */
18769
- draft: number;
18770
- /** @description Non-negative integer (0 or greater) */
18771
- submitted: number;
18772
- /** @description Non-negative integer (0 or greater) */
18773
- accepted: number;
18774
- /** @description Non-negative integer (0 or greater) */
18775
- declined: number;
18776
- /** @description Non-negative integer (0 or greater) */
18777
- cancelled: number;
18778
- /** @description Non-negative integer (0 or greater) */
18779
- expired?: number;
18780
- };
18781
- /** @description Inquiry total counts for coordinator */
18782
- totals: {
18783
- /** @description Non-negative integer (0 or greater) */
18784
- all: number;
18785
- /** @description Non-negative integer (0 or greater) */
18786
- active: number;
18787
- /** @description Non-negative integer (0 or greater) */
18788
- needsAction?: number;
18789
- /** @description Non-negative integer (0 or greater) */
18790
- inProgress?: number;
18791
- };
18792
- alerts?: {
18793
- type: 'info' | 'warning' | 'error' | 'action_required';
18794
- severity: 'low' | 'medium' | 'high';
18795
- /** @description Non-negative integer (0 or greater) */
18796
- count: number;
18797
- message: string;
18798
- status: string;
18799
- }[];
18800
- };
18801
- /** @description Metadata about the statistics query and response */
18802
- metadata: {
18803
- /** @description Role context for the statistics query */
18804
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
18805
- /**
18806
- * Format: uuid
18807
- * @description UUID version 4 identifier
18808
- */
18809
- accountId?: string;
18810
- /**
18811
- * Format: uuid
18812
- * @description UUID version 4 identifier
18813
- */
18814
- userId?: string;
18815
- /**
18816
- * Format: date-time
18817
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18818
- */
18819
- queriedAt: string;
18820
- /** @description Whether the result was served from cache */
18821
- cached?: boolean;
18822
- /**
18823
- * Format: date-time
18824
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18825
- */
18826
- cacheExpiresAt?: string;
18827
- };
18828
- };
18829
- };
18830
- };
18831
- };
18832
- };
18833
- put?: never;
18834
- post?: never;
18835
- delete?: never;
18836
- options?: never;
18837
- head?: never;
18838
- patch?: never;
18839
- trace?: never;
18840
- };
18841
- '/api/inquiries/assistant/stats': {
18842
- parameters: {
18843
- query?: never;
18844
- header?: never;
18845
- path?: never;
18846
- cookie?: never;
18847
- };
18848
- /**
18849
- * Get inquiry statistics for assistants
18850
- * @description Get statistics for inquiries received by assistants
18851
- */
18852
- get: {
18853
- parameters: {
18854
- query?: never;
18855
- header?: never;
18856
- path?: never;
18857
- cookie?: never;
18858
- };
18859
- requestBody?: never;
18860
- responses: {
18861
- /** @description Standard statistics response wrapper */
18862
- 200: {
18863
- headers: {
18864
- [name: string]: unknown;
18865
- };
18866
- content: {
18867
- 'application/json': {
18868
- /** @description Inquiry statistics for assistants */
18869
- data: {
18870
- /** @description Inquiry counts by status from assistant perspective */
18871
- byStatus: {
18872
- /** @description Non-negative integer (0 or greater) */
18873
- submitted?: number;
18874
- /** @description Non-negative integer (0 or greater) */
18875
- accepted?: number;
18876
- /** @description Non-negative integer (0 or greater) */
18877
- declined?: number;
18878
- };
18879
- /** @description Inquiry total counts for assistant */
18880
- totals: {
18881
- /** @description Non-negative integer (0 or greater) */
18882
- all: number;
18883
- /** @description Non-negative integer (0 or greater) */
18884
- active: number;
18885
- /** @description Non-negative integer (0 or greater) */
18886
- needsAction?: number;
18887
- /** @description Non-negative integer (0 or greater) */
18888
- inProgress?: number;
18889
- };
18890
- alerts?: {
18891
- type: 'info' | 'warning' | 'error' | 'action_required';
18892
- severity: 'low' | 'medium' | 'high';
18893
- /** @description Non-negative integer (0 or greater) */
18894
- count: number;
18895
- message: string;
18896
- status: string;
18897
- }[];
18898
- };
18899
- /** @description Metadata about the statistics query and response */
18900
- metadata: {
18901
- /** @description Role context for the statistics query */
18902
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
18903
- /**
18904
- * Format: uuid
18905
- * @description UUID version 4 identifier
18906
- */
18907
- accountId?: string;
18908
- /**
18909
- * Format: uuid
18910
- * @description UUID version 4 identifier
18911
- */
18912
- userId?: string;
18913
- /**
18914
- * Format: date-time
18915
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18916
- */
18917
- queriedAt: string;
18918
- /** @description Whether the result was served from cache */
18919
- cached?: boolean;
18920
- /**
18921
- * Format: date-time
18922
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
18923
- */
18924
- cacheExpiresAt?: string;
18925
- };
18926
- };
18927
- };
18928
- };
18929
- };
18930
- };
18931
- put?: never;
18932
- post?: never;
18933
- delete?: never;
18934
- options?: never;
18935
- head?: never;
18936
- patch?: never;
18937
- trace?: never;
18938
- };
18939
17595
  '/api/inquiries/{id}/contracts': {
18940
17596
  parameters: {
18941
17597
  query?: never;
@@ -19137,191 +17793,6 @@ export interface paths {
19137
17793
  patch?: never;
19138
17794
  trace?: never;
19139
17795
  };
19140
- '/api/invites/sent/stats': {
19141
- parameters: {
19142
- query?: never;
19143
- header?: never;
19144
- path?: never;
19145
- cookie?: never;
19146
- };
19147
- /**
19148
- * Get sent invite statistics
19149
- * @description Get statistics for invites sent by the current user (inviter perspective)
19150
- */
19151
- get: {
19152
- parameters: {
19153
- query?: never;
19154
- header?: never;
19155
- path?: never;
19156
- cookie?: never;
19157
- };
19158
- requestBody?: never;
19159
- responses: {
19160
- /** @description Default Response */
19161
- 200: {
19162
- headers: {
19163
- [name: string]: unknown;
19164
- };
19165
- content: {
19166
- 'application/json': {
19167
- data: {
19168
- totals: {
19169
- all: number;
19170
- needsAction: number;
19171
- };
19172
- byStatus?: {
19173
- draft?: number;
19174
- submitted?: number;
19175
- accepted?: number;
19176
- declined?: number;
19177
- cancelled?: number;
19178
- expired?: number;
19179
- };
19180
- };
19181
- metadata: {
19182
- role?: string;
19183
- userId?: string;
19184
- cached?: boolean;
19185
- queriedAt?: string;
19186
- timestamp?: string;
19187
- };
19188
- };
19189
- };
19190
- };
19191
- };
19192
- };
19193
- put?: never;
19194
- post?: never;
19195
- delete?: never;
19196
- options?: never;
19197
- head?: never;
19198
- patch?: never;
19199
- trace?: never;
19200
- };
19201
- '/api/invites/received/stats': {
19202
- parameters: {
19203
- query?: never;
19204
- header?: never;
19205
- path?: never;
19206
- cookie?: never;
19207
- };
19208
- /**
19209
- * Get received invite statistics
19210
- * @description Get statistics for invites received by the current user (invitee perspective)
19211
- */
19212
- get: {
19213
- parameters: {
19214
- query?: never;
19215
- header?: never;
19216
- path?: never;
19217
- cookie?: never;
19218
- };
19219
- requestBody?: never;
19220
- responses: {
19221
- /** @description Default Response */
19222
- 200: {
19223
- headers: {
19224
- [name: string]: unknown;
19225
- };
19226
- content: {
19227
- 'application/json': {
19228
- data: {
19229
- totals: {
19230
- all: number;
19231
- needsAction: number;
19232
- };
19233
- byStatus?: {
19234
- draft?: number;
19235
- submitted?: number;
19236
- accepted?: number;
19237
- declined?: number;
19238
- cancelled?: number;
19239
- expired?: number;
19240
- };
19241
- };
19242
- metadata: {
19243
- role?: string;
19244
- userId?: string;
19245
- cached?: boolean;
19246
- queriedAt?: string;
19247
- timestamp?: string;
19248
- };
19249
- };
19250
- };
19251
- };
19252
- };
19253
- };
19254
- put?: never;
19255
- post?: never;
19256
- delete?: never;
19257
- options?: never;
19258
- head?: never;
19259
- patch?: never;
19260
- trace?: never;
19261
- };
19262
- '/api/invites/stats': {
19263
- parameters: {
19264
- query?: never;
19265
- header?: never;
19266
- path?: never;
19267
- cookie?: never;
19268
- };
19269
- /**
19270
- * Get invite statistics (deprecated)
19271
- * @description Get statistical overview of invites for the current user. Use /sent/stats or /received/stats instead.
19272
- */
19273
- get: {
19274
- parameters: {
19275
- query?: {
19276
- role?: string;
19277
- };
19278
- header?: never;
19279
- path?: never;
19280
- cookie?: never;
19281
- };
19282
- requestBody?: never;
19283
- responses: {
19284
- /** @description Default Response */
19285
- 200: {
19286
- headers: {
19287
- [name: string]: unknown;
19288
- };
19289
- content: {
19290
- 'application/json': {
19291
- data: {
19292
- totals: {
19293
- all: number;
19294
- needsAction: number;
19295
- };
19296
- byStatus?: {
19297
- draft?: number;
19298
- submitted?: number;
19299
- accepted?: number;
19300
- declined?: number;
19301
- cancelled?: number;
19302
- expired?: number;
19303
- };
19304
- };
19305
- metadata: {
19306
- role?: string;
19307
- userId?: string;
19308
- cached?: boolean;
19309
- queriedAt?: string;
19310
- timestamp?: string;
19311
- };
19312
- };
19313
- };
19314
- };
19315
- };
19316
- };
19317
- put?: never;
19318
- post?: never;
19319
- delete?: never;
19320
- options?: never;
19321
- head?: never;
19322
- patch?: never;
19323
- trace?: never;
19324
- };
19325
17796
  '/api/invites/assistants': {
19326
17797
  parameters: {
19327
17798
  query?: never;
@@ -19419,7 +17890,7 @@ export interface paths {
19419
17890
  } & {
19420
17891
  message: string;
19421
17892
  } & {
19422
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
17893
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
19423
17894
  /** Format: date-time */
19424
17895
  status_changed_at: string;
19425
17896
  } & {
@@ -19432,6 +17903,7 @@ export interface paths {
19432
17903
  declined_at: string | null;
19433
17904
  cancelled_at: string | null;
19434
17905
  expired_at: string | null;
17906
+ contracted_at: string | null;
19435
17907
  /** Format: date-time */
19436
17908
  created_at: string;
19437
17909
  /** Format: date-time */
@@ -19557,7 +18029,7 @@ export interface paths {
19557
18029
  } & {
19558
18030
  message: string;
19559
18031
  } & {
19560
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
18032
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
19561
18033
  /** Format: date-time */
19562
18034
  status_changed_at: string;
19563
18035
  } & {
@@ -19570,6 +18042,7 @@ export interface paths {
19570
18042
  declined_at: string | null;
19571
18043
  cancelled_at: string | null;
19572
18044
  expired_at: string | null;
18045
+ contracted_at: string | null;
19573
18046
  /** Format: date-time */
19574
18047
  created_at: string;
19575
18048
  /** Format: date-time */
@@ -19694,7 +18167,7 @@ export interface paths {
19694
18167
  } & {
19695
18168
  message: string;
19696
18169
  } & {
19697
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
18170
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
19698
18171
  /** Format: date-time */
19699
18172
  status_changed_at: string;
19700
18173
  } & {
@@ -19707,6 +18180,7 @@ export interface paths {
19707
18180
  declined_at: string | null;
19708
18181
  cancelled_at: string | null;
19709
18182
  expired_at: string | null;
18183
+ contracted_at: string | null;
19710
18184
  /** Format: date-time */
19711
18185
  created_at: string;
19712
18186
  /** Format: date-time */
@@ -19830,7 +18304,7 @@ export interface paths {
19830
18304
  } & {
19831
18305
  message: string;
19832
18306
  } & {
19833
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
18307
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
19834
18308
  /** Format: date-time */
19835
18309
  status_changed_at: string;
19836
18310
  } & {
@@ -19843,6 +18317,7 @@ export interface paths {
19843
18317
  declined_at: string | null;
19844
18318
  cancelled_at: string | null;
19845
18319
  expired_at: string | null;
18320
+ contracted_at: string | null;
19846
18321
  /** Format: date-time */
19847
18322
  created_at: string;
19848
18323
  /** Format: date-time */
@@ -20103,7 +18578,7 @@ export interface paths {
20103
18578
  } & {
20104
18579
  message: string;
20105
18580
  } & {
20106
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
18581
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20107
18582
  /** Format: date-time */
20108
18583
  status_changed_at: string;
20109
18584
  } & {
@@ -20116,6 +18591,7 @@ export interface paths {
20116
18591
  declined_at: string | null;
20117
18592
  cancelled_at: string | null;
20118
18593
  expired_at: string | null;
18594
+ contracted_at: string | null;
20119
18595
  /** Format: date-time */
20120
18596
  created_at: string;
20121
18597
  /** Format: date-time */
@@ -20248,7 +18724,7 @@ export interface paths {
20248
18724
  } & {
20249
18725
  message: string;
20250
18726
  } & {
20251
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
18727
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20252
18728
  /** Format: date-time */
20253
18729
  status_changed_at: string;
20254
18730
  } & {
@@ -20261,6 +18737,7 @@ export interface paths {
20261
18737
  declined_at: string | null;
20262
18738
  cancelled_at: string | null;
20263
18739
  expired_at: string | null;
18740
+ contracted_at: string | null;
20264
18741
  /** Format: date-time */
20265
18742
  created_at: string;
20266
18743
  /** Format: date-time */
@@ -20393,7 +18870,7 @@ export interface paths {
20393
18870
  } & {
20394
18871
  message: string;
20395
18872
  } & {
20396
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
18873
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20397
18874
  /** Format: date-time */
20398
18875
  status_changed_at: string;
20399
18876
  } & {
@@ -20406,6 +18883,7 @@ export interface paths {
20406
18883
  declined_at: string | null;
20407
18884
  cancelled_at: string | null;
20408
18885
  expired_at: string | null;
18886
+ contracted_at: string | null;
20409
18887
  /** Format: date-time */
20410
18888
  created_at: string;
20411
18889
  /** Format: date-time */
@@ -20538,7 +19016,7 @@ export interface paths {
20538
19016
  } & {
20539
19017
  message: string;
20540
19018
  } & {
20541
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
19019
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20542
19020
  /** Format: date-time */
20543
19021
  status_changed_at: string;
20544
19022
  } & {
@@ -20551,6 +19029,7 @@ export interface paths {
20551
19029
  declined_at: string | null;
20552
19030
  cancelled_at: string | null;
20553
19031
  expired_at: string | null;
19032
+ contracted_at: string | null;
20554
19033
  /** Format: date-time */
20555
19034
  created_at: string;
20556
19035
  /** Format: date-time */
@@ -20627,6 +19106,207 @@ export interface paths {
20627
19106
  patch?: never;
20628
19107
  trace?: never;
20629
19108
  };
19109
+ '/api/invites/{inviteId}/contracts': {
19110
+ parameters: {
19111
+ query?: never;
19112
+ header?: never;
19113
+ path?: never;
19114
+ cookie?: never;
19115
+ };
19116
+ get?: never;
19117
+ put?: never;
19118
+ /**
19119
+ * Create contract from invite
19120
+ * @description Create a contract from an accepted invite
19121
+ */
19122
+ post: {
19123
+ parameters: {
19124
+ query?: never;
19125
+ header?: never;
19126
+ path: {
19127
+ inviteId: string;
19128
+ };
19129
+ cookie?: never;
19130
+ };
19131
+ requestBody?: {
19132
+ content: {
19133
+ 'application/json': {
19134
+ /**
19135
+ * @default ORDINARY
19136
+ * @enum {string}
19137
+ */
19138
+ contract_type?: 'ORDINARY' | 'TEMPORARY' | 'SUMMONING';
19139
+ service_type?: string;
19140
+ hours_per_week?: number;
19141
+ hourly_rate?: number;
19142
+ /** Format: date */
19143
+ start_date?: string;
19144
+ /** Format: date */
19145
+ end_date?: string;
19146
+ };
19147
+ };
19148
+ };
19149
+ responses: {
19150
+ /** @description Default Response */
19151
+ 201: {
19152
+ headers: {
19153
+ [name: string]: unknown;
19154
+ };
19155
+ content: {
19156
+ 'application/json': {
19157
+ data: {
19158
+ /** Format: uuid */
19159
+ id: string;
19160
+ contract_number?: string | null;
19161
+ /** Format: uuid */
19162
+ employer_id: string;
19163
+ worker_id?: string | null;
19164
+ application_id?: string | null;
19165
+ inquiry_id?: string | null;
19166
+ account_id?: string | null;
19167
+ arrangement_id?: string | null;
19168
+ arrangement_title?: string | null;
19169
+ conversation_id?: string | null;
19170
+ /** Format: uuid */
19171
+ contract_type_id: string;
19172
+ contract_type?: string | null;
19173
+ contract_type_title?: string | null;
19174
+ service_type?: string | null;
19175
+ salary_type_name?: string | null;
19176
+ current_salary_amount?: number | null;
19177
+ salary_id?: string | null;
19178
+ source_invite_id?: string | null;
19179
+ is_employer_also_worker?: boolean | null;
19180
+ is_salary_manually_overridden?: boolean | null;
19181
+ requires_background_check?: boolean | null;
19182
+ requires_health_certificate?: boolean | null;
19183
+ title?: string | null;
19184
+ contract_details?: string | null;
19185
+ hours_per_week?: number | null;
19186
+ hourly_rate?: number | null;
19187
+ start_date?: string | null;
19188
+ end_date?: string | null;
19189
+ status: unknown;
19190
+ lifecycle_changed_at?: string | null;
19191
+ status_changed_at?: string | null;
19192
+ employer_email?: string | null;
19193
+ employer_first_name?: string | null;
19194
+ employer_last_name?: string | null;
19195
+ employer_phone?: string | null;
19196
+ worker_personal_number?: string | null;
19197
+ worker_bank_account?: string | null;
19198
+ worker_email?: string | null;
19199
+ worker_name?: string | null;
19200
+ worker_first_name?: string | null;
19201
+ worker_last_name?: string | null;
19202
+ worker_phone?: string | null;
19203
+ worker_phone_number?: string | null;
19204
+ worker_has_previous_employment?: boolean | null;
19205
+ worker_previous_employment_details?: string | null;
19206
+ worker_has_prior_assistant_experience?: boolean | null;
19207
+ worker_has_prior_uloba_employment?: boolean | null;
19208
+ worker_is_related_to_employer?: boolean | null;
19209
+ worker_has_uloba_as_primary_employer?: boolean | null;
19210
+ worker_requires_health_certificate?: boolean | null;
19211
+ worker_requires_tuberculosis_test?: boolean | null;
19212
+ worker_citizenship?: string | null;
19213
+ worker_substitute_for_name?: string | null;
19214
+ worker_address_street?: string | null;
19215
+ worker_address_postal_code?: string | null;
19216
+ worker_address_city?: string | null;
19217
+ worker_address_country?: string | null;
19218
+ worker_emergency_contact_name?: string | null;
19219
+ worker_emergency_contact_phone?: string | null;
19220
+ worker_emergency_contact_relation?: string | null;
19221
+ decision_owner_id?: string | null;
19222
+ decision_owner_name?: string | null;
19223
+ decision_owner_same_as_coordinator?: boolean | null;
19224
+ phase_1_submission_completed_at?: string | null;
19225
+ phase_1_submission_completed_by?: string | null;
19226
+ phase_1_submission_completed_by_name?: string | null;
19227
+ phase_2_submission_completed_at?: string | null;
19228
+ phase_2_submission_completed_by?: string | null;
19229
+ phase_2_submission_completed_by_name?: string | null;
19230
+ direct_submitted_at?: string | null;
19231
+ direct_submitted_by?: string | null;
19232
+ direct_submitted_by_name?: string | null;
19233
+ submitted_by?: string | null;
19234
+ submitted_by_name?: string | null;
19235
+ submitted_at?: string | null;
19236
+ submitted_to_uloba_at?: string | null;
19237
+ submitted_to_uloba_by?: string | null;
19238
+ submitted_to_uloba_by_name?: string | null;
19239
+ coordinator_submitted_at?: string | null;
19240
+ coordinator_submitted_by?: string | null;
19241
+ worker_submitted_at?: string | null;
19242
+ worker_submitted_by?: string | null;
19243
+ ready_for_submission_at?: string | null;
19244
+ ready_for_submission_by?: string | null;
19245
+ draft_at?: string | null;
19246
+ draft_by?: string | null;
19247
+ validation_failed_at?: string | null;
19248
+ validation_failed_by?: string | null;
19249
+ in_review_at?: string | null;
19250
+ in_review_by?: string | null;
19251
+ ready_for_signing_at?: string | null;
19252
+ ready_for_signing_by?: string | null;
19253
+ pending_signing_at?: string | null;
19254
+ pending_signing_by?: string | null;
19255
+ signed_at?: string | null;
19256
+ signed_by?: string | null;
19257
+ activated_at?: string | null;
19258
+ activated_by?: string | null;
19259
+ activated_by_name?: string | null;
19260
+ completed_at?: string | null;
19261
+ completed_by?: string | null;
19262
+ completed_by_name?: string | null;
19263
+ terminated_at?: string | null;
19264
+ terminated_by?: string | null;
19265
+ terminated_by_name?: string | null;
19266
+ terminated_message?: string | null;
19267
+ terminated_reason?: string | null;
19268
+ rejected_at?: string | null;
19269
+ rejected_by?: string | null;
19270
+ rejected_by_name?: string | null;
19271
+ rejected_message?: string | null;
19272
+ rejected_reason?: string | null;
19273
+ cancelled_at?: string | null;
19274
+ cancelled_by?: string | null;
19275
+ cancelled_by_name?: string | null;
19276
+ cancelled_message?: string | null;
19277
+ cancelled_reason?: string | null;
19278
+ temporary_position_reason?: string | null;
19279
+ archived_by_employer?: boolean | null;
19280
+ archived_at_employer?: string | null;
19281
+ archived_by_worker?: boolean | null;
19282
+ archived_at_worker?: string | null;
19283
+ validation_status?: string | null;
19284
+ validation_errors?: unknown;
19285
+ validation_report?: unknown;
19286
+ last_validated_at?: string | null;
19287
+ created_at?: string | null;
19288
+ updated_at?: string | null;
19289
+ };
19290
+ metadata: {
19291
+ /** @description Viewer relationship to the resource */
19292
+ viewerContext: 'anonymous' | 'authenticated' | 'owner' | 'coordinator' | 'admin' | 'employer' | 'worker';
19293
+ permissions: {
19294
+ canView: boolean;
19295
+ canEdit: boolean;
19296
+ canDelete: boolean;
19297
+ };
19298
+ };
19299
+ };
19300
+ };
19301
+ };
19302
+ };
19303
+ };
19304
+ delete?: never;
19305
+ options?: never;
19306
+ head?: never;
19307
+ patch?: never;
19308
+ trace?: never;
19309
+ };
20630
19310
  '/api/invites/{inviteId}/send-reminder': {
20631
19311
  parameters: {
20632
19312
  query?: never;
@@ -20676,7 +19356,7 @@ export interface paths {
20676
19356
  } & {
20677
19357
  message: string;
20678
19358
  } & {
20679
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
19359
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20680
19360
  /** Format: date-time */
20681
19361
  status_changed_at: string;
20682
19362
  } & {
@@ -20689,6 +19369,7 @@ export interface paths {
20689
19369
  declined_at: string | null;
20690
19370
  cancelled_at: string | null;
20691
19371
  expired_at: string | null;
19372
+ contracted_at: string | null;
20692
19373
  /** Format: date-time */
20693
19374
  created_at: string;
20694
19375
  /** Format: date-time */
@@ -20840,7 +19521,7 @@ export interface paths {
20840
19521
  } & {
20841
19522
  message: string;
20842
19523
  } & {
20843
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
19524
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20844
19525
  /** Format: date-time */
20845
19526
  status_changed_at: string;
20846
19527
  } & {
@@ -20853,6 +19534,7 @@ export interface paths {
20853
19534
  declined_at: string | null;
20854
19535
  cancelled_at: string | null;
20855
19536
  expired_at: string | null;
19537
+ contracted_at: string | null;
20856
19538
  /** Format: date-time */
20857
19539
  created_at: string;
20858
19540
  /** Format: date-time */
@@ -20978,7 +19660,7 @@ export interface paths {
20978
19660
  } & {
20979
19661
  message: string;
20980
19662
  } & {
20981
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
19663
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
20982
19664
  /** Format: date-time */
20983
19665
  status_changed_at: string;
20984
19666
  } & {
@@ -20991,6 +19673,7 @@ export interface paths {
20991
19673
  declined_at: string | null;
20992
19674
  cancelled_at: string | null;
20993
19675
  expired_at: string | null;
19676
+ contracted_at: string | null;
20994
19677
  /** Format: date-time */
20995
19678
  created_at: string;
20996
19679
  /** Format: date-time */
@@ -21116,7 +19799,7 @@ export interface paths {
21116
19799
  } & {
21117
19800
  message: string;
21118
19801
  } & {
21119
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
19802
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
21120
19803
  /** Format: date-time */
21121
19804
  status_changed_at: string;
21122
19805
  } & {
@@ -21129,6 +19812,7 @@ export interface paths {
21129
19812
  declined_at: string | null;
21130
19813
  cancelled_at: string | null;
21131
19814
  expired_at: string | null;
19815
+ contracted_at: string | null;
21132
19816
  /** Format: date-time */
21133
19817
  created_at: string;
21134
19818
  /** Format: date-time */
@@ -21254,7 +19938,7 @@ export interface paths {
21254
19938
  } & {
21255
19939
  message: string;
21256
19940
  } & {
21257
- status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired';
19941
+ status: 'draft' | 'submitted' | 'accepted' | 'declined' | 'cancelled' | 'expired' | 'contracted';
21258
19942
  /** Format: date-time */
21259
19943
  status_changed_at: string;
21260
19944
  } & {
@@ -21267,6 +19951,7 @@ export interface paths {
21267
19951
  declined_at: string | null;
21268
19952
  cancelled_at: string | null;
21269
19953
  expired_at: string | null;
19954
+ contracted_at: string | null;
21270
19955
  /** Format: date-time */
21271
19956
  created_at: string;
21272
19957
  /** Format: date-time */
@@ -21343,73 +20028,6 @@ export interface paths {
21343
20028
  patch?: never;
21344
20029
  trace?: never;
21345
20030
  };
21346
- '/api/invites/{inviteId}/contracts': {
21347
- parameters: {
21348
- query?: never;
21349
- header?: never;
21350
- path?: never;
21351
- cookie?: never;
21352
- };
21353
- get?: never;
21354
- put?: never;
21355
- /**
21356
- * Create contract from invite
21357
- * @description Create a contract from an accepted invite
21358
- */
21359
- post: {
21360
- parameters: {
21361
- query?: never;
21362
- header?: never;
21363
- path: {
21364
- inviteId: string;
21365
- };
21366
- cookie?: never;
21367
- };
21368
- requestBody?: {
21369
- content: {
21370
- 'application/json': {
21371
- contract_type?: string;
21372
- service_type?: string;
21373
- hours_per_week?: number;
21374
- hourly_rate?: number;
21375
- start_date?: string;
21376
- end_date?: string;
21377
- };
21378
- };
21379
- };
21380
- responses: {
21381
- /** @description Default Response */
21382
- 201: {
21383
- headers: {
21384
- [name: string]: unknown;
21385
- };
21386
- content: {
21387
- 'application/json': {
21388
- id: string;
21389
- employer_id: string;
21390
- worker_id: string;
21391
- account_id: string;
21392
- invite_id: string;
21393
- job_id?: string;
21394
- contract_type_id: string;
21395
- status: string;
21396
- hours_per_week?: number;
21397
- hourly_rate?: number;
21398
- start_date?: string;
21399
- end_date?: string;
21400
- created_at: string;
21401
- updated_at: string;
21402
- };
21403
- };
21404
- };
21405
- };
21406
- };
21407
- delete?: never;
21408
- options?: never;
21409
- head?: never;
21410
- patch?: never;
21411
- trace?: never;
21412
- };
21413
20031
  '/api/invites/pending': {
21414
20032
  parameters: {
21415
20033
  query?: never;
@@ -30476,486 +29094,6 @@ export interface paths {
30476
29094
  patch?: never;
30477
29095
  trace?: never;
30478
29096
  };
30479
- '/api/contracts/employer/stats': {
30480
- parameters: {
30481
- query?: never;
30482
- header?: never;
30483
- path?: never;
30484
- cookie?: never;
30485
- };
30486
- /**
30487
- * Get contract statistics for employers
30488
- * @description Get statistics for contracts from employer perspective
30489
- */
30490
- get: {
30491
- parameters: {
30492
- query?: never;
30493
- header?: never;
30494
- path?: never;
30495
- cookie?: never;
30496
- };
30497
- requestBody?: never;
30498
- responses: {
30499
- /** @description Standard statistics response wrapper */
30500
- 200: {
30501
- headers: {
30502
- [name: string]: unknown;
30503
- };
30504
- content: {
30505
- 'application/json': {
30506
- /** @description Complete contract statistics data */
30507
- data: {
30508
- /** @description Contract counts by all possible statuses */
30509
- byStatus: {
30510
- /** @description Non-negative integer (0 or greater) */
30511
- draft: number;
30512
- /** @description Non-negative integer (0 or greater) */
30513
- coordinator_submitted: number;
30514
- /** @description Non-negative integer (0 or greater) */
30515
- worker_submitted: number;
30516
- /** @description Non-negative integer (0 or greater) */
30517
- ready_for_submission: number;
30518
- /** @description Non-negative integer (0 or greater) */
30519
- validation_failed: number;
30520
- /** @description Non-negative integer (0 or greater) */
30521
- submitted: number;
30522
- /** @description Non-negative integer (0 or greater) */
30523
- in_review: number;
30524
- /** @description Non-negative integer (0 or greater) */
30525
- ready_for_signing: number;
30526
- /** @description Non-negative integer (0 or greater) */
30527
- pending_signing: number;
30528
- /** @description Non-negative integer (0 or greater) */
30529
- signed: number;
30530
- /** @description Non-negative integer (0 or greater) */
30531
- active: number;
30532
- /** @description Non-negative integer (0 or greater) */
30533
- completed: number;
30534
- /** @description Non-negative integer (0 or greater) */
30535
- terminated: number;
30536
- /** @description Non-negative integer (0 or greater) */
30537
- cancelled: number;
30538
- };
30539
- /** @description Contract total counts and derived metrics */
30540
- totals: {
30541
- /** @description Non-negative integer (0 or greater) */
30542
- all: number;
30543
- /** @description Non-negative integer (0 or greater) */
30544
- active: number;
30545
- /** @description Non-negative integer (0 or greater) */
30546
- inProgress?: number;
30547
- /** @description Non-negative integer (0 or greater) */
30548
- needsAction?: number;
30549
- };
30550
- /** @description Role-specific alerts for contracts requiring attention */
30551
- alerts?: {
30552
- type: string;
30553
- severity: string;
30554
- count: number;
30555
- message: string;
30556
- status: string;
30557
- }[];
30558
- };
30559
- /** @description Metadata about the statistics query and response */
30560
- metadata: {
30561
- /** @description Role context for the statistics query */
30562
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
30563
- /**
30564
- * Format: uuid
30565
- * @description UUID version 4 identifier
30566
- */
30567
- accountId?: string;
30568
- /**
30569
- * Format: uuid
30570
- * @description UUID version 4 identifier
30571
- */
30572
- userId?: string;
30573
- /**
30574
- * Format: date-time
30575
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30576
- */
30577
- queriedAt: string;
30578
- /** @description Whether the result was served from cache */
30579
- cached?: boolean;
30580
- /**
30581
- * Format: date-time
30582
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30583
- */
30584
- cacheExpiresAt?: string;
30585
- };
30586
- };
30587
- };
30588
- };
30589
- };
30590
- };
30591
- put?: never;
30592
- post?: never;
30593
- delete?: never;
30594
- options?: never;
30595
- head?: never;
30596
- patch?: never;
30597
- trace?: never;
30598
- };
30599
- '/api/contracts/teamlead/stats': {
30600
- parameters: {
30601
- query?: never;
30602
- header?: never;
30603
- path?: never;
30604
- cookie?: never;
30605
- };
30606
- /**
30607
- * [DEPRECATED] Get contract statistics for team leaders
30608
- * @description DEPRECATED: Use /contracts/employer/stats instead
30609
- */
30610
- get: {
30611
- parameters: {
30612
- query?: never;
30613
- header?: never;
30614
- path?: never;
30615
- cookie?: never;
30616
- };
30617
- requestBody?: never;
30618
- responses: {
30619
- /** @description Standard statistics response wrapper */
30620
- 200: {
30621
- headers: {
30622
- [name: string]: unknown;
30623
- };
30624
- content: {
30625
- 'application/json': {
30626
- /** @description Complete contract statistics data */
30627
- data: {
30628
- /** @description Contract counts by all possible statuses */
30629
- byStatus: {
30630
- /** @description Non-negative integer (0 or greater) */
30631
- draft: number;
30632
- /** @description Non-negative integer (0 or greater) */
30633
- coordinator_submitted: number;
30634
- /** @description Non-negative integer (0 or greater) */
30635
- worker_submitted: number;
30636
- /** @description Non-negative integer (0 or greater) */
30637
- ready_for_submission: number;
30638
- /** @description Non-negative integer (0 or greater) */
30639
- validation_failed: number;
30640
- /** @description Non-negative integer (0 or greater) */
30641
- submitted: number;
30642
- /** @description Non-negative integer (0 or greater) */
30643
- in_review: number;
30644
- /** @description Non-negative integer (0 or greater) */
30645
- ready_for_signing: number;
30646
- /** @description Non-negative integer (0 or greater) */
30647
- pending_signing: number;
30648
- /** @description Non-negative integer (0 or greater) */
30649
- signed: number;
30650
- /** @description Non-negative integer (0 or greater) */
30651
- active: number;
30652
- /** @description Non-negative integer (0 or greater) */
30653
- completed: number;
30654
- /** @description Non-negative integer (0 or greater) */
30655
- terminated: number;
30656
- /** @description Non-negative integer (0 or greater) */
30657
- cancelled: number;
30658
- };
30659
- /** @description Contract total counts and derived metrics */
30660
- totals: {
30661
- /** @description Non-negative integer (0 or greater) */
30662
- all: number;
30663
- /** @description Non-negative integer (0 or greater) */
30664
- active: number;
30665
- /** @description Non-negative integer (0 or greater) */
30666
- inProgress?: number;
30667
- /** @description Non-negative integer (0 or greater) */
30668
- needsAction?: number;
30669
- };
30670
- /** @description Role-specific alerts for contracts requiring attention */
30671
- alerts?: {
30672
- type: string;
30673
- severity: string;
30674
- count: number;
30675
- message: string;
30676
- status: string;
30677
- }[];
30678
- };
30679
- /** @description Metadata about the statistics query and response */
30680
- metadata: {
30681
- /** @description Role context for the statistics query */
30682
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
30683
- /**
30684
- * Format: uuid
30685
- * @description UUID version 4 identifier
30686
- */
30687
- accountId?: string;
30688
- /**
30689
- * Format: uuid
30690
- * @description UUID version 4 identifier
30691
- */
30692
- userId?: string;
30693
- /**
30694
- * Format: date-time
30695
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30696
- */
30697
- queriedAt: string;
30698
- /** @description Whether the result was served from cache */
30699
- cached?: boolean;
30700
- /**
30701
- * Format: date-time
30702
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30703
- */
30704
- cacheExpiresAt?: string;
30705
- };
30706
- };
30707
- };
30708
- };
30709
- };
30710
- };
30711
- put?: never;
30712
- post?: never;
30713
- delete?: never;
30714
- options?: never;
30715
- head?: never;
30716
- patch?: never;
30717
- trace?: never;
30718
- };
30719
- '/api/contracts/worker/stats': {
30720
- parameters: {
30721
- query?: never;
30722
- header?: never;
30723
- path?: never;
30724
- cookie?: never;
30725
- };
30726
- /**
30727
- * Get contract statistics for workers
30728
- * @description Get statistics for contracts from worker perspective
30729
- */
30730
- get: {
30731
- parameters: {
30732
- query?: never;
30733
- header?: never;
30734
- path?: never;
30735
- cookie?: never;
30736
- };
30737
- requestBody?: never;
30738
- responses: {
30739
- /** @description Standard statistics response wrapper */
30740
- 200: {
30741
- headers: {
30742
- [name: string]: unknown;
30743
- };
30744
- content: {
30745
- 'application/json': {
30746
- /** @description Complete contract statistics data */
30747
- data: {
30748
- /** @description Contract counts by all possible statuses */
30749
- byStatus: {
30750
- /** @description Non-negative integer (0 or greater) */
30751
- draft: number;
30752
- /** @description Non-negative integer (0 or greater) */
30753
- coordinator_submitted: number;
30754
- /** @description Non-negative integer (0 or greater) */
30755
- worker_submitted: number;
30756
- /** @description Non-negative integer (0 or greater) */
30757
- ready_for_submission: number;
30758
- /** @description Non-negative integer (0 or greater) */
30759
- validation_failed: number;
30760
- /** @description Non-negative integer (0 or greater) */
30761
- submitted: number;
30762
- /** @description Non-negative integer (0 or greater) */
30763
- in_review: number;
30764
- /** @description Non-negative integer (0 or greater) */
30765
- ready_for_signing: number;
30766
- /** @description Non-negative integer (0 or greater) */
30767
- pending_signing: number;
30768
- /** @description Non-negative integer (0 or greater) */
30769
- signed: number;
30770
- /** @description Non-negative integer (0 or greater) */
30771
- active: number;
30772
- /** @description Non-negative integer (0 or greater) */
30773
- completed: number;
30774
- /** @description Non-negative integer (0 or greater) */
30775
- terminated: number;
30776
- /** @description Non-negative integer (0 or greater) */
30777
- cancelled: number;
30778
- };
30779
- /** @description Contract total counts and derived metrics */
30780
- totals: {
30781
- /** @description Non-negative integer (0 or greater) */
30782
- all: number;
30783
- /** @description Non-negative integer (0 or greater) */
30784
- active: number;
30785
- /** @description Non-negative integer (0 or greater) */
30786
- inProgress?: number;
30787
- /** @description Non-negative integer (0 or greater) */
30788
- needsAction?: number;
30789
- };
30790
- /** @description Role-specific alerts for contracts requiring attention */
30791
- alerts?: {
30792
- type: string;
30793
- severity: string;
30794
- count: number;
30795
- message: string;
30796
- status: string;
30797
- }[];
30798
- };
30799
- /** @description Metadata about the statistics query and response */
30800
- metadata: {
30801
- /** @description Role context for the statistics query */
30802
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
30803
- /**
30804
- * Format: uuid
30805
- * @description UUID version 4 identifier
30806
- */
30807
- accountId?: string;
30808
- /**
30809
- * Format: uuid
30810
- * @description UUID version 4 identifier
30811
- */
30812
- userId?: string;
30813
- /**
30814
- * Format: date-time
30815
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30816
- */
30817
- queriedAt: string;
30818
- /** @description Whether the result was served from cache */
30819
- cached?: boolean;
30820
- /**
30821
- * Format: date-time
30822
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30823
- */
30824
- cacheExpiresAt?: string;
30825
- };
30826
- };
30827
- };
30828
- };
30829
- };
30830
- };
30831
- put?: never;
30832
- post?: never;
30833
- delete?: never;
30834
- options?: never;
30835
- head?: never;
30836
- patch?: never;
30837
- trace?: never;
30838
- };
30839
- '/api/contracts/assistant/stats': {
30840
- parameters: {
30841
- query?: never;
30842
- header?: never;
30843
- path?: never;
30844
- cookie?: never;
30845
- };
30846
- /**
30847
- * [DEPRECATED] Get contract statistics for assistants
30848
- * @description DEPRECATED: Use /contracts/worker/stats instead
30849
- */
30850
- get: {
30851
- parameters: {
30852
- query?: never;
30853
- header?: never;
30854
- path?: never;
30855
- cookie?: never;
30856
- };
30857
- requestBody?: never;
30858
- responses: {
30859
- /** @description Standard statistics response wrapper */
30860
- 200: {
30861
- headers: {
30862
- [name: string]: unknown;
30863
- };
30864
- content: {
30865
- 'application/json': {
30866
- /** @description Complete contract statistics data */
30867
- data: {
30868
- /** @description Contract counts by all possible statuses */
30869
- byStatus: {
30870
- /** @description Non-negative integer (0 or greater) */
30871
- draft: number;
30872
- /** @description Non-negative integer (0 or greater) */
30873
- coordinator_submitted: number;
30874
- /** @description Non-negative integer (0 or greater) */
30875
- worker_submitted: number;
30876
- /** @description Non-negative integer (0 or greater) */
30877
- ready_for_submission: number;
30878
- /** @description Non-negative integer (0 or greater) */
30879
- validation_failed: number;
30880
- /** @description Non-negative integer (0 or greater) */
30881
- submitted: number;
30882
- /** @description Non-negative integer (0 or greater) */
30883
- in_review: number;
30884
- /** @description Non-negative integer (0 or greater) */
30885
- ready_for_signing: number;
30886
- /** @description Non-negative integer (0 or greater) */
30887
- pending_signing: number;
30888
- /** @description Non-negative integer (0 or greater) */
30889
- signed: number;
30890
- /** @description Non-negative integer (0 or greater) */
30891
- active: number;
30892
- /** @description Non-negative integer (0 or greater) */
30893
- completed: number;
30894
- /** @description Non-negative integer (0 or greater) */
30895
- terminated: number;
30896
- /** @description Non-negative integer (0 or greater) */
30897
- cancelled: number;
30898
- };
30899
- /** @description Contract total counts and derived metrics */
30900
- totals: {
30901
- /** @description Non-negative integer (0 or greater) */
30902
- all: number;
30903
- /** @description Non-negative integer (0 or greater) */
30904
- active: number;
30905
- /** @description Non-negative integer (0 or greater) */
30906
- inProgress?: number;
30907
- /** @description Non-negative integer (0 or greater) */
30908
- needsAction?: number;
30909
- };
30910
- /** @description Role-specific alerts for contracts requiring attention */
30911
- alerts?: {
30912
- type: string;
30913
- severity: string;
30914
- count: number;
30915
- message: string;
30916
- status: string;
30917
- }[];
30918
- };
30919
- /** @description Metadata about the statistics query and response */
30920
- metadata: {
30921
- /** @description Role context for the statistics query */
30922
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
30923
- /**
30924
- * Format: uuid
30925
- * @description UUID version 4 identifier
30926
- */
30927
- accountId?: string;
30928
- /**
30929
- * Format: uuid
30930
- * @description UUID version 4 identifier
30931
- */
30932
- userId?: string;
30933
- /**
30934
- * Format: date-time
30935
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30936
- */
30937
- queriedAt: string;
30938
- /** @description Whether the result was served from cache */
30939
- cached?: boolean;
30940
- /**
30941
- * Format: date-time
30942
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
30943
- */
30944
- cacheExpiresAt?: string;
30945
- };
30946
- };
30947
- };
30948
- };
30949
- };
30950
- };
30951
- put?: never;
30952
- post?: never;
30953
- delete?: never;
30954
- options?: never;
30955
- head?: never;
30956
- patch?: never;
30957
- trace?: never;
30958
- };
30959
29097
  '/api/contract-cases/{id}': {
30960
29098
  parameters: {
30961
29099
  query?: never;
@@ -41046,6 +39184,26 @@ export interface paths {
41046
39184
  active: number;
41047
39185
  needsAction: number;
41048
39186
  inProgress: number;
39187
+ unassigned?: number;
39188
+ draft?: number;
39189
+ submitted?: number;
39190
+ waitingResponse?: number;
39191
+ approved?: number;
39192
+ rejected?: number;
39193
+ accepted?: number;
39194
+ declined?: number;
39195
+ cancelled?: number;
39196
+ expired?: number;
39197
+ pending?: number;
39198
+ signed?: number;
39199
+ active_contract?: number;
39200
+ completed?: number;
39201
+ terminated?: number;
39202
+ published?: number;
39203
+ unpublished?: number;
39204
+ expiringSoon?: number;
39205
+ expiringUrgent?: number;
39206
+ inactive?: number;
41049
39207
  };
41050
39208
  alerts?: {
41051
39209
  severity: 'low' | 'medium' | 'high' | 'critical';
@@ -41612,7 +39770,484 @@ export interface paths {
41612
39770
  };
41613
39771
  content: {
41614
39772
  'application/json': {
41615
- /** @description Complete overview data for teamlead/arbeidsleder */
39773
+ /** @description Simplified overview data for teamlead (100% data products + actions API) */
39774
+ data: {
39775
+ /** @description Simplified summary metrics for teamlead overview */
39776
+ summary: {
39777
+ /** @description Non-negative integer (0 or greater) */
39778
+ jobsTotal: number;
39779
+ /** @description Non-negative integer (0 or greater) */
39780
+ jobsActive: number;
39781
+ /** @description Non-negative integer (0 or greater) */
39782
+ applicationsTotal: number;
39783
+ /** @description Non-negative integer (0 or greater) */
39784
+ applicationsActive: number;
39785
+ /** @description Non-negative integer (0 or greater) */
39786
+ inquiriesTotal: number;
39787
+ /** @description Non-negative integer (0 or greater) */
39788
+ inquiriesActive: number;
39789
+ /** @description Non-negative integer (0 or greater) */
39790
+ invitesTotal: number;
39791
+ /** @description Non-negative integer (0 or greater) */
39792
+ invitesActive: number;
39793
+ /** @description Non-negative integer (0 or greater) */
39794
+ contractsTotal: number;
39795
+ /** @description Non-negative integer (0 or greater) */
39796
+ contractsActive: number;
39797
+ };
39798
+ /** @description Job viewing statistics across different time periods for coordinator */
39799
+ jobsViews: {
39800
+ /** @description Non-negative integer (0 or greater) */
39801
+ totalViews: number;
39802
+ /** @description Non-negative integer (0 or greater) */
39803
+ viewsLast7Days: number;
39804
+ /** @description Non-negative integer (0 or greater) */
39805
+ viewsLast30Days: number;
39806
+ /** @description Non-negative integer (0 or greater) */
39807
+ viewsLast60Days: number;
39808
+ /** @description Non-negative integer (0 or greater) */
39809
+ viewsLast3Months: number;
39810
+ /** @description Non-negative integer (0 or greater) */
39811
+ viewsLast6Months: number;
39812
+ /** @description Non-negative integer (0 or greater) */
39813
+ viewsLast12Months: number;
39814
+ /** @description Non-negative integer (0 or greater) */
39815
+ uniqueViewers: number;
39816
+ lastViewedAt: string | null;
39817
+ };
39818
+ /** @description Top actions from Actions API */
39819
+ quickActions: {
39820
+ type: string;
39821
+ label: string;
39822
+ description: string;
39823
+ /** @description Non-negative integer (0 or greater) */
39824
+ count: number;
39825
+ priority: 'low' | 'medium' | 'high' | 'critical';
39826
+ metadata: {
39827
+ entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract' | 'profile';
39828
+ status?: string;
39829
+ filters?: {
39830
+ [key: string]: string;
39831
+ };
39832
+ };
39833
+ }[];
39834
+ };
39835
+ metadata: {
39836
+ /** @description Role context for the statistics query */
39837
+ role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
39838
+ /**
39839
+ * Format: uuid
39840
+ * @description UUID version 4 identifier
39841
+ */
39842
+ accountId?: string;
39843
+ /**
39844
+ * Format: uuid
39845
+ * @description UUID version 4 identifier
39846
+ */
39847
+ userId?: string;
39848
+ /**
39849
+ * Format: date-time
39850
+ * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
39851
+ */
39852
+ queriedAt: string;
39853
+ /** @description Whether the result was served from cache */
39854
+ cached?: boolean;
39855
+ /**
39856
+ * Format: date-time
39857
+ * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
39858
+ */
39859
+ cacheExpiresAt?: string;
39860
+ /** @description List of entity types included in the overview */
39861
+ entitiesIncluded: string[];
39862
+ /** @description Total query time in milliseconds */
39863
+ queryTimeMs?: number;
39864
+ };
39865
+ };
39866
+ };
39867
+ };
39868
+ /** @description Default Response */
39869
+ 403: {
39870
+ headers: {
39871
+ [name: string]: unknown;
39872
+ };
39873
+ content: {
39874
+ 'application/json': {
39875
+ error: {
39876
+ code: 'UNAUTHORIZED' | 'FORBIDDEN' | 'TOKEN_EXPIRED' | 'INVALID_TOKEN' | 'VALIDATION_ERROR' | 'INVALID_INPUT' | 'MISSING_REQUIRED_FIELD' | 'INVALID_FORMAT' | 'NOT_FOUND' | 'ALREADY_EXISTS' | 'CONFLICT' | 'GONE' | 'BUSINESS_RULE_VIOLATION' | 'INVALID_STATE_TRANSITION' | 'QUOTA_EXCEEDED' | 'RATE_LIMIT_EXCEEDED' | 'INTERNAL_ERROR' | 'DATABASE_ERROR' | 'EXTERNAL_SERVICE_ERROR' | 'TIMEOUT' | 'SERVICE_UNAVAILABLE';
39877
+ /** @description Human-readable error message */
39878
+ message: string;
39879
+ details?: {
39880
+ /** @description Field-level validation errors */
39881
+ fields?: {
39882
+ /** @description Field name that failed validation */
39883
+ field: string;
39884
+ /** @description Human-readable error message */
39885
+ message: string;
39886
+ /** @description The invalid value that was provided */
39887
+ value?: unknown;
39888
+ /** @description The validation constraint that failed */
39889
+ constraint?: string;
39890
+ }[];
39891
+ /** @description Stack trace (only in development) */
39892
+ stack?: string[];
39893
+ /** @description Original error object (only in development) */
39894
+ originalError?: unknown;
39895
+ } & {
39896
+ [key: string]: unknown;
39897
+ };
39898
+ /**
39899
+ * Format: date-time
39900
+ * @description ISO 8601 timestamp of when the error occurred
39901
+ */
39902
+ timestamp: string;
39903
+ /** @description Request path that caused the error */
39904
+ path?: string;
39905
+ /**
39906
+ * @description HTTP method that caused the error
39907
+ * @enum {string}
39908
+ */
39909
+ method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'HEAD' | 'OPTIONS';
39910
+ /** @description Unique request identifier for tracing */
39911
+ requestId?: string;
39912
+ };
39913
+ };
39914
+ };
39915
+ };
39916
+ /** @description Default Response */
39917
+ 500: {
39918
+ headers: {
39919
+ [name: string]: unknown;
39920
+ };
39921
+ content: {
39922
+ 'application/json': {
39923
+ error: {
39924
+ code: 'UNAUTHORIZED' | 'FORBIDDEN' | 'TOKEN_EXPIRED' | 'INVALID_TOKEN' | 'VALIDATION_ERROR' | 'INVALID_INPUT' | 'MISSING_REQUIRED_FIELD' | 'INVALID_FORMAT' | 'NOT_FOUND' | 'ALREADY_EXISTS' | 'CONFLICT' | 'GONE' | 'BUSINESS_RULE_VIOLATION' | 'INVALID_STATE_TRANSITION' | 'QUOTA_EXCEEDED' | 'RATE_LIMIT_EXCEEDED' | 'INTERNAL_ERROR' | 'DATABASE_ERROR' | 'EXTERNAL_SERVICE_ERROR' | 'TIMEOUT' | 'SERVICE_UNAVAILABLE';
39925
+ /** @description Human-readable error message */
39926
+ message: string;
39927
+ details?: {
39928
+ /** @description Field-level validation errors */
39929
+ fields?: {
39930
+ /** @description Field name that failed validation */
39931
+ field: string;
39932
+ /** @description Human-readable error message */
39933
+ message: string;
39934
+ /** @description The invalid value that was provided */
39935
+ value?: unknown;
39936
+ /** @description The validation constraint that failed */
39937
+ constraint?: string;
39938
+ }[];
39939
+ /** @description Stack trace (only in development) */
39940
+ stack?: string[];
39941
+ /** @description Original error object (only in development) */
39942
+ originalError?: unknown;
39943
+ } & {
39944
+ [key: string]: unknown;
39945
+ };
39946
+ /**
39947
+ * Format: date-time
39948
+ * @description ISO 8601 timestamp of when the error occurred
39949
+ */
39950
+ timestamp: string;
39951
+ /** @description Request path that caused the error */
39952
+ path?: string;
39953
+ /**
39954
+ * @description HTTP method that caused the error
39955
+ * @enum {string}
39956
+ */
39957
+ method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'HEAD' | 'OPTIONS';
39958
+ /** @description Unique request identifier for tracing */
39959
+ requestId?: string;
39960
+ };
39961
+ };
39962
+ };
39963
+ };
39964
+ };
39965
+ };
39966
+ put?: never;
39967
+ post?: never;
39968
+ delete?: never;
39969
+ options?: never;
39970
+ head?: never;
39971
+ patch?: never;
39972
+ trace?: never;
39973
+ };
39974
+ '/api/overview/assistant': {
39975
+ parameters: {
39976
+ query?: never;
39977
+ header?: never;
39978
+ path?: never;
39979
+ cookie?: never;
39980
+ };
39981
+ /**
39982
+ * Get assistant overview
39983
+ * @description Get complete dashboard overview for assistant/assistent including stats, activities, and alerts from all entities
39984
+ */
39985
+ get: {
39986
+ parameters: {
39987
+ query?: never;
39988
+ header?: never;
39989
+ path?: never;
39990
+ cookie?: never;
39991
+ };
39992
+ requestBody?: never;
39993
+ responses: {
39994
+ /** @description Complete overview response for assistant */
39995
+ 200: {
39996
+ headers: {
39997
+ [name: string]: unknown;
39998
+ };
39999
+ content: {
40000
+ 'application/json': {
40001
+ /** @description Simplified overview data for assistant (100% data products + actions API) */
40002
+ data: {
40003
+ /** @description Simplified summary metrics for assistant overview */
40004
+ summary: {
40005
+ /** @description Non-negative integer (0 or greater) */
40006
+ applicationsTotal: number;
40007
+ /** @description Non-negative integer (0 or greater) */
40008
+ applicationsActive: number;
40009
+ /** @description Non-negative integer (0 or greater) */
40010
+ inquiriesTotal: number;
40011
+ /** @description Non-negative integer (0 or greater) */
40012
+ inquiriesActive: number;
40013
+ /** @description Non-negative integer (0 or greater) */
40014
+ contractsTotal: number;
40015
+ /** @description Non-negative integer (0 or greater) */
40016
+ contractsActive: number;
40017
+ };
40018
+ /** @description Assistant profile status and completion */
40019
+ profileStatus: {
40020
+ exists: boolean;
40021
+ status: 'not_created' | 'draft' | 'private' | 'public';
40022
+ completionPercentage: number;
40023
+ missingFields: string[];
40024
+ };
40025
+ /** @description User saved jobs with 5 most recent */
40026
+ savedJobs: {
40027
+ /** @description Non-negative integer (0 or greater) */
40028
+ total: number;
40029
+ recentJobs: {
40030
+ id: string;
40031
+ title: string;
40032
+ location: string;
40033
+ deadline: string | null;
40034
+ status: string;
40035
+ /**
40036
+ * Format: date-time
40037
+ * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
40038
+ */
40039
+ savedAt: string;
40040
+ }[];
40041
+ };
40042
+ /** @description Unread messages count */
40043
+ unreadMessages: {
40044
+ /** @description Non-negative integer (0 or greater) */
40045
+ count: number;
40046
+ /** @description Non-negative integer (0 or greater) */
40047
+ conversations: number;
40048
+ };
40049
+ /** @description Profile view statistics across different time periods */
40050
+ profileViews: {
40051
+ /** @description Non-negative integer (0 or greater) */
40052
+ totalViews: number;
40053
+ /** @description Non-negative integer (0 or greater) */
40054
+ viewsLast7Days: number;
40055
+ /** @description Non-negative integer (0 or greater) */
40056
+ viewsLast30Days: number;
40057
+ /** @description Non-negative integer (0 or greater) */
40058
+ viewsLast3Months: number;
40059
+ /** @description Non-negative integer (0 or greater) */
40060
+ viewsLast6Months: number;
40061
+ /** @description Non-negative integer (0 or greater) */
40062
+ viewsLast12Months: number;
40063
+ /** @description Non-negative integer (0 or greater) */
40064
+ uniqueViewers: number;
40065
+ lastViewedAt: string | null;
40066
+ };
40067
+ /** @description Top 10 suggested next actions from Actions API */
40068
+ quickActions: {
40069
+ type: string;
40070
+ label: string;
40071
+ description: string;
40072
+ /** @description Non-negative integer (0 or greater) */
40073
+ count: number;
40074
+ priority: 'low' | 'medium' | 'high' | 'critical';
40075
+ metadata: {
40076
+ entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract' | 'profile';
40077
+ status?: string;
40078
+ filters?: {
40079
+ [key: string]: string;
40080
+ };
40081
+ };
40082
+ }[];
40083
+ };
40084
+ metadata: {
40085
+ /** @description Role context for the statistics query */
40086
+ role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
40087
+ /**
40088
+ * Format: uuid
40089
+ * @description UUID version 4 identifier
40090
+ */
40091
+ accountId?: string;
40092
+ /**
40093
+ * Format: uuid
40094
+ * @description UUID version 4 identifier
40095
+ */
40096
+ userId?: string;
40097
+ /**
40098
+ * Format: date-time
40099
+ * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
40100
+ */
40101
+ queriedAt: string;
40102
+ /** @description Whether the result was served from cache */
40103
+ cached?: boolean;
40104
+ /**
40105
+ * Format: date-time
40106
+ * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
40107
+ */
40108
+ cacheExpiresAt?: string;
40109
+ /** @description List of entity types included in the overview */
40110
+ entitiesIncluded: string[];
40111
+ /** @description Total query time in milliseconds */
40112
+ queryTimeMs?: number;
40113
+ };
40114
+ };
40115
+ };
40116
+ };
40117
+ /** @description Default Response */
40118
+ 403: {
40119
+ headers: {
40120
+ [name: string]: unknown;
40121
+ };
40122
+ content: {
40123
+ 'application/json': {
40124
+ error: {
40125
+ code: 'UNAUTHORIZED' | 'FORBIDDEN' | 'TOKEN_EXPIRED' | 'INVALID_TOKEN' | 'VALIDATION_ERROR' | 'INVALID_INPUT' | 'MISSING_REQUIRED_FIELD' | 'INVALID_FORMAT' | 'NOT_FOUND' | 'ALREADY_EXISTS' | 'CONFLICT' | 'GONE' | 'BUSINESS_RULE_VIOLATION' | 'INVALID_STATE_TRANSITION' | 'QUOTA_EXCEEDED' | 'RATE_LIMIT_EXCEEDED' | 'INTERNAL_ERROR' | 'DATABASE_ERROR' | 'EXTERNAL_SERVICE_ERROR' | 'TIMEOUT' | 'SERVICE_UNAVAILABLE';
40126
+ /** @description Human-readable error message */
40127
+ message: string;
40128
+ details?: {
40129
+ /** @description Field-level validation errors */
40130
+ fields?: {
40131
+ /** @description Field name that failed validation */
40132
+ field: string;
40133
+ /** @description Human-readable error message */
40134
+ message: string;
40135
+ /** @description The invalid value that was provided */
40136
+ value?: unknown;
40137
+ /** @description The validation constraint that failed */
40138
+ constraint?: string;
40139
+ }[];
40140
+ /** @description Stack trace (only in development) */
40141
+ stack?: string[];
40142
+ /** @description Original error object (only in development) */
40143
+ originalError?: unknown;
40144
+ } & {
40145
+ [key: string]: unknown;
40146
+ };
40147
+ /**
40148
+ * Format: date-time
40149
+ * @description ISO 8601 timestamp of when the error occurred
40150
+ */
40151
+ timestamp: string;
40152
+ /** @description Request path that caused the error */
40153
+ path?: string;
40154
+ /**
40155
+ * @description HTTP method that caused the error
40156
+ * @enum {string}
40157
+ */
40158
+ method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'HEAD' | 'OPTIONS';
40159
+ /** @description Unique request identifier for tracing */
40160
+ requestId?: string;
40161
+ };
40162
+ };
40163
+ };
40164
+ };
40165
+ /** @description Default Response */
40166
+ 500: {
40167
+ headers: {
40168
+ [name: string]: unknown;
40169
+ };
40170
+ content: {
40171
+ 'application/json': {
40172
+ error: {
40173
+ code: 'UNAUTHORIZED' | 'FORBIDDEN' | 'TOKEN_EXPIRED' | 'INVALID_TOKEN' | 'VALIDATION_ERROR' | 'INVALID_INPUT' | 'MISSING_REQUIRED_FIELD' | 'INVALID_FORMAT' | 'NOT_FOUND' | 'ALREADY_EXISTS' | 'CONFLICT' | 'GONE' | 'BUSINESS_RULE_VIOLATION' | 'INVALID_STATE_TRANSITION' | 'QUOTA_EXCEEDED' | 'RATE_LIMIT_EXCEEDED' | 'INTERNAL_ERROR' | 'DATABASE_ERROR' | 'EXTERNAL_SERVICE_ERROR' | 'TIMEOUT' | 'SERVICE_UNAVAILABLE';
40174
+ /** @description Human-readable error message */
40175
+ message: string;
40176
+ details?: {
40177
+ /** @description Field-level validation errors */
40178
+ fields?: {
40179
+ /** @description Field name that failed validation */
40180
+ field: string;
40181
+ /** @description Human-readable error message */
40182
+ message: string;
40183
+ /** @description The invalid value that was provided */
40184
+ value?: unknown;
40185
+ /** @description The validation constraint that failed */
40186
+ constraint?: string;
40187
+ }[];
40188
+ /** @description Stack trace (only in development) */
40189
+ stack?: string[];
40190
+ /** @description Original error object (only in development) */
40191
+ originalError?: unknown;
40192
+ } & {
40193
+ [key: string]: unknown;
40194
+ };
40195
+ /**
40196
+ * Format: date-time
40197
+ * @description ISO 8601 timestamp of when the error occurred
40198
+ */
40199
+ timestamp: string;
40200
+ /** @description Request path that caused the error */
40201
+ path?: string;
40202
+ /**
40203
+ * @description HTTP method that caused the error
40204
+ * @enum {string}
40205
+ */
40206
+ method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE' | 'HEAD' | 'OPTIONS';
40207
+ /** @description Unique request identifier for tracing */
40208
+ requestId?: string;
40209
+ };
40210
+ };
40211
+ };
40212
+ };
40213
+ };
40214
+ };
40215
+ put?: never;
40216
+ post?: never;
40217
+ delete?: never;
40218
+ options?: never;
40219
+ head?: never;
40220
+ patch?: never;
40221
+ trace?: never;
40222
+ };
40223
+ '/api/overview/casehandler': {
40224
+ parameters: {
40225
+ query?: never;
40226
+ header?: never;
40227
+ path?: never;
40228
+ cookie?: never;
40229
+ };
40230
+ /**
40231
+ * Get casehandler overview
40232
+ * @description Get complete dashboard overview for case handler/saksbehandler including stats, activities, and alerts from contract cases
40233
+ */
40234
+ get: {
40235
+ parameters: {
40236
+ query?: never;
40237
+ header?: never;
40238
+ path?: never;
40239
+ cookie?: never;
40240
+ };
40241
+ requestBody?: never;
40242
+ responses: {
40243
+ /** @description Complete overview response for case handler */
40244
+ 200: {
40245
+ headers: {
40246
+ [name: string]: unknown;
40247
+ };
40248
+ content: {
40249
+ 'application/json': {
40250
+ /** @description Complete overview data for case handler/saksbehandler */
41616
40251
  data: {
41617
40252
  /** @description High-level summary metrics across all entities */
41618
40253
  summary: {
@@ -41631,105 +40266,9 @@ export interface paths {
41631
40266
  /** @description Non-negative integer (0 or greater) */
41632
40267
  total?: number;
41633
40268
  };
41634
- /** @description Stats for each entity type managed by teamlead */
40269
+ /** @description Stats for contract cases managed by case handler */
41635
40270
  entities: {
41636
- jobs: {
41637
- byStatus: {
41638
- [key: string]: number;
41639
- };
41640
- totals: {
41641
- /** @description Non-negative integer (0 or greater) */
41642
- all: number;
41643
- /** @description Non-negative integer (0 or greater) */
41644
- active: number;
41645
- /** @description Non-negative integer (0 or greater) */
41646
- needsAction?: number;
41647
- /** @description Non-negative integer (0 or greater) */
41648
- inProgress?: number;
41649
- };
41650
- alerts?: {
41651
- type: 'info' | 'warning' | 'error' | 'action_required';
41652
- severity: 'low' | 'medium' | 'high';
41653
- /** @description Non-negative integer (0 or greater) */
41654
- count: number;
41655
- message: string;
41656
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
41657
- status?: string;
41658
- }[];
41659
- };
41660
- applications: {
41661
- byStatus: {
41662
- [key: string]: number;
41663
- };
41664
- totals: {
41665
- /** @description Non-negative integer (0 or greater) */
41666
- all: number;
41667
- /** @description Non-negative integer (0 or greater) */
41668
- active: number;
41669
- /** @description Non-negative integer (0 or greater) */
41670
- needsAction?: number;
41671
- /** @description Non-negative integer (0 or greater) */
41672
- inProgress?: number;
41673
- };
41674
- alerts?: {
41675
- type: 'info' | 'warning' | 'error' | 'action_required';
41676
- severity: 'low' | 'medium' | 'high';
41677
- /** @description Non-negative integer (0 or greater) */
41678
- count: number;
41679
- message: string;
41680
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
41681
- status?: string;
41682
- }[];
41683
- };
41684
- inquiries: {
41685
- byStatus: {
41686
- [key: string]: number;
41687
- };
41688
- totals: {
41689
- /** @description Non-negative integer (0 or greater) */
41690
- all: number;
41691
- /** @description Non-negative integer (0 or greater) */
41692
- active: number;
41693
- /** @description Non-negative integer (0 or greater) */
41694
- needsAction?: number;
41695
- /** @description Non-negative integer (0 or greater) */
41696
- inProgress?: number;
41697
- };
41698
- alerts?: {
41699
- type: 'info' | 'warning' | 'error' | 'action_required';
41700
- severity: 'low' | 'medium' | 'high';
41701
- /** @description Non-negative integer (0 or greater) */
41702
- count: number;
41703
- message: string;
41704
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
41705
- status?: string;
41706
- }[];
41707
- };
41708
- invites: {
41709
- byStatus: {
41710
- [key: string]: number;
41711
- };
41712
- totals: {
41713
- /** @description Non-negative integer (0 or greater) */
41714
- all: number;
41715
- /** @description Non-negative integer (0 or greater) */
41716
- active: number;
41717
- /** @description Non-negative integer (0 or greater) */
41718
- needsAction?: number;
41719
- /** @description Non-negative integer (0 or greater) */
41720
- inProgress?: number;
41721
- };
41722
- alerts?: {
41723
- type: 'info' | 'warning' | 'error' | 'action_required';
41724
- severity: 'low' | 'medium' | 'high';
41725
- /** @description Non-negative integer (0 or greater) */
41726
- count: number;
41727
- message: string;
41728
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
41729
- status?: string;
41730
- }[];
41731
- };
41732
- contracts: {
40271
+ cases: {
41733
40272
  byStatus: {
41734
40273
  [key: string]: number;
41735
40274
  };
@@ -41754,7 +40293,7 @@ export interface paths {
41754
40293
  }[];
41755
40294
  };
41756
40295
  };
41757
- /** @description Recent activities across all entities (last 10) */
40296
+ /** @description Recent activities across all cases (last 10) */
41758
40297
  recentActivities: {
41759
40298
  id: string;
41760
40299
  entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
@@ -41770,7 +40309,7 @@ export interface paths {
41770
40309
  [key: string]: unknown;
41771
40310
  };
41772
40311
  }[];
41773
- /** @description All alerts from all entities, sorted by priority */
40312
+ /** @description All alerts from all cases, sorted by priority */
41774
40313
  aggregatedAlerts: {
41775
40314
  type: 'info' | 'warning' | 'error' | 'action_required';
41776
40315
  severity: 'low' | 'medium' | 'high';
@@ -41780,7 +40319,7 @@ export interface paths {
41780
40319
  entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
41781
40320
  status?: string;
41782
40321
  }[];
41783
- /** @description Suggested next actions for the user */
40322
+ /** @description Suggested next actions for the case handler */
41784
40323
  quickActions: {
41785
40324
  type: string;
41786
40325
  label: string;
@@ -41936,7 +40475,7 @@ export interface paths {
41936
40475
  patch?: never;
41937
40476
  trace?: never;
41938
40477
  };
41939
- '/api/overview/assistant': {
40478
+ '/api/overview/platform': {
41940
40479
  parameters: {
41941
40480
  query?: never;
41942
40481
  header?: never;
@@ -41944,8 +40483,8 @@ export interface paths {
41944
40483
  cookie?: never;
41945
40484
  };
41946
40485
  /**
41947
- * Get assistant overview
41948
- * @description Get complete dashboard overview for assistant/assistent including stats, activities, and alerts from all entities
40486
+ * Get platform overview
40487
+ * @description Get complete platform-wide overview for admin/drift including aggregated stats across ALL users and accounts
41949
40488
  */
41950
40489
  get: {
41951
40490
  parameters: {
@@ -41956,33 +40495,29 @@ export interface paths {
41956
40495
  };
41957
40496
  requestBody?: never;
41958
40497
  responses: {
41959
- /** @description Complete overview response for assistant */
40498
+ /** @description Complete platform overview response for admin/drift */
41960
40499
  200: {
41961
40500
  headers: {
41962
40501
  [name: string]: unknown;
41963
40502
  };
41964
40503
  content: {
41965
40504
  'application/json': {
41966
- /** @description Complete overview data for assistant/assistent */
40505
+ /** @description Complete platform overview data for admin/drift */
41967
40506
  data: {
41968
- /** @description High-level summary metrics across all entities */
40507
+ /** @description High-level summary metrics across the entire platform */
41969
40508
  summary: {
41970
40509
  /** @description Non-negative integer (0 or greater) */
41971
- incoming?: number;
41972
- /** @description Non-negative integer (0 or greater) */
41973
- myCases?: number;
41974
- /** @description Non-negative integer (0 or greater) */
41975
- onHold?: number;
40510
+ totalEntities: number;
41976
40511
  /** @description Non-negative integer (0 or greater) */
41977
- inProgress: number;
40512
+ activeItems: number;
41978
40513
  /** @description Non-negative integer (0 or greater) */
41979
- needsAction?: number;
40514
+ inProgressItems: number;
41980
40515
  /** @description Non-negative integer (0 or greater) */
41981
- active?: number;
40516
+ usersTotal: number;
41982
40517
  /** @description Non-negative integer (0 or greater) */
41983
- total?: number;
40518
+ usersActive30d: number;
41984
40519
  };
41985
- /** @description Stats for each entity type relevant to assistant */
40520
+ /** @description Platform-wide stats for each entity type */
41986
40521
  entities: {
41987
40522
  jobs: {
41988
40523
  byStatus: {
@@ -42104,24 +40639,27 @@ export interface paths {
42104
40639
  status?: string;
42105
40640
  }[];
42106
40641
  };
42107
- };
42108
- /** @description Recent activities across all entities (last 10) */
42109
- recentActivities: {
42110
- id: string;
42111
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42112
- entityId: string;
42113
- action: string;
42114
- description: string;
42115
- /**
42116
- * Format: date-time
42117
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42118
- */
42119
- timestamp: string;
42120
- metadata?: {
42121
- [key: string]: unknown;
40642
+ users: {
40643
+ /** @description Non-negative integer (0 or greater) */
40644
+ total_users: number;
40645
+ /** @description Non-negative integer (0 or greater) */
40646
+ active_users_30d: number;
40647
+ /** @description Non-negative integer (0 or greater) */
40648
+ active_users_7d: number;
40649
+ /** @description Non-negative integer (0 or greater) */
40650
+ active_users_1d: number;
40651
+ /** @description Non-negative integer (0 or greater) */
40652
+ new_users_30d: number;
40653
+ /** @description Non-negative integer (0 or greater) */
40654
+ new_users_7d: number;
40655
+ /**
40656
+ * Format: date-time
40657
+ * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
40658
+ */
40659
+ refreshed_at: string;
42122
40660
  };
42123
- }[];
42124
- /** @description All alerts from all entities, sorted by priority */
40661
+ };
40662
+ /** @description All platform alerts, sorted by priority */
42125
40663
  aggregatedAlerts: {
42126
40664
  type: 'info' | 'warning' | 'error' | 'action_required';
42127
40665
  severity: 'low' | 'medium' | 'high';
@@ -42131,22 +40669,6 @@ export interface paths {
42131
40669
  entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42132
40670
  status?: string;
42133
40671
  }[];
42134
- /** @description Suggested next actions for the user */
42135
- quickActions: {
42136
- type: string;
42137
- label: string;
42138
- description: string;
42139
- /** @description Non-negative integer (0 or greater) */
42140
- count: number;
42141
- priority: 'low' | 'medium' | 'high' | 'critical';
42142
- metadata: {
42143
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract' | 'profile';
42144
- status?: string;
42145
- filters?: {
42146
- [key: string]: string;
42147
- };
42148
- };
42149
- }[];
42150
40672
  };
42151
40673
  metadata: {
42152
40674
  /** @description Role context for the statistics query */
@@ -42287,7 +40809,7 @@ export interface paths {
42287
40809
  patch?: never;
42288
40810
  trace?: never;
42289
40811
  };
42290
- '/api/overview/casehandler': {
40812
+ '/api/overview/platform/analytics': {
42291
40813
  parameters: {
42292
40814
  query?: never;
42293
40815
  header?: never;
@@ -42295,147 +40817,21 @@ export interface paths {
42295
40817
  cookie?: never;
42296
40818
  };
42297
40819
  /**
42298
- * Get casehandler overview
42299
- * @description Get complete dashboard overview for case handler/saksbehandler including stats, activities, and alerts from contract cases
40820
+ * Get platform analytics
40821
+ * @description Get platform-wide analytics including time-series data, trends, conversion metrics, and health indicators
42300
40822
  */
42301
40823
  get: {
42302
40824
  parameters: {
42303
- query?: never;
40825
+ query?: {
40826
+ /** @description Time period for analytics data */
40827
+ period?: '7d' | '30d' | '90d';
40828
+ };
42304
40829
  header?: never;
42305
40830
  path?: never;
42306
40831
  cookie?: never;
42307
40832
  };
42308
40833
  requestBody?: never;
42309
40834
  responses: {
42310
- /** @description Complete overview response for case handler */
42311
- 200: {
42312
- headers: {
42313
- [name: string]: unknown;
42314
- };
42315
- content: {
42316
- 'application/json': {
42317
- /** @description Complete overview data for case handler/saksbehandler */
42318
- data: {
42319
- /** @description High-level summary metrics across all entities */
42320
- summary: {
42321
- /** @description Non-negative integer (0 or greater) */
42322
- incoming?: number;
42323
- /** @description Non-negative integer (0 or greater) */
42324
- myCases?: number;
42325
- /** @description Non-negative integer (0 or greater) */
42326
- onHold?: number;
42327
- /** @description Non-negative integer (0 or greater) */
42328
- inProgress: number;
42329
- /** @description Non-negative integer (0 or greater) */
42330
- needsAction?: number;
42331
- /** @description Non-negative integer (0 or greater) */
42332
- active?: number;
42333
- /** @description Non-negative integer (0 or greater) */
42334
- total?: number;
42335
- };
42336
- /** @description Stats for contract cases managed by case handler */
42337
- entities: {
42338
- cases: {
42339
- byStatus: {
42340
- [key: string]: number;
42341
- };
42342
- totals: {
42343
- /** @description Non-negative integer (0 or greater) */
42344
- all: number;
42345
- /** @description Non-negative integer (0 or greater) */
42346
- active: number;
42347
- /** @description Non-negative integer (0 or greater) */
42348
- needsAction?: number;
42349
- /** @description Non-negative integer (0 or greater) */
42350
- inProgress?: number;
42351
- };
42352
- alerts?: {
42353
- type: 'info' | 'warning' | 'error' | 'action_required';
42354
- severity: 'low' | 'medium' | 'high';
42355
- /** @description Non-negative integer (0 or greater) */
42356
- count: number;
42357
- message: string;
42358
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42359
- status?: string;
42360
- }[];
42361
- };
42362
- };
42363
- /** @description Recent activities across all cases (last 10) */
42364
- recentActivities: {
42365
- id: string;
42366
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42367
- entityId: string;
42368
- action: string;
42369
- description: string;
42370
- /**
42371
- * Format: date-time
42372
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42373
- */
42374
- timestamp: string;
42375
- metadata?: {
42376
- [key: string]: unknown;
42377
- };
42378
- }[];
42379
- /** @description All alerts from all cases, sorted by priority */
42380
- aggregatedAlerts: {
42381
- type: 'info' | 'warning' | 'error' | 'action_required';
42382
- severity: 'low' | 'medium' | 'high';
42383
- /** @description Non-negative integer (0 or greater) */
42384
- count: number;
42385
- message: string;
42386
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42387
- status?: string;
42388
- }[];
42389
- /** @description Suggested next actions for the case handler */
42390
- quickActions: {
42391
- type: string;
42392
- label: string;
42393
- description: string;
42394
- /** @description Non-negative integer (0 or greater) */
42395
- count: number;
42396
- priority: 'low' | 'medium' | 'high' | 'critical';
42397
- metadata: {
42398
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract' | 'profile';
42399
- status?: string;
42400
- filters?: {
42401
- [key: string]: string;
42402
- };
42403
- };
42404
- }[];
42405
- };
42406
- metadata: {
42407
- /** @description Role context for the statistics query */
42408
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
42409
- /**
42410
- * Format: uuid
42411
- * @description UUID version 4 identifier
42412
- */
42413
- accountId?: string;
42414
- /**
42415
- * Format: uuid
42416
- * @description UUID version 4 identifier
42417
- */
42418
- userId?: string;
42419
- /**
42420
- * Format: date-time
42421
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42422
- */
42423
- queriedAt: string;
42424
- /** @description Whether the result was served from cache */
42425
- cached?: boolean;
42426
- /**
42427
- * Format: date-time
42428
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42429
- */
42430
- cacheExpiresAt?: string;
42431
- /** @description List of entity types included in the overview */
42432
- entitiesIncluded: string[];
42433
- /** @description Total query time in milliseconds */
42434
- queryTimeMs?: number;
42435
- };
42436
- };
42437
- };
42438
- };
42439
40835
  /** @description Default Response */
42440
40836
  403: {
42441
40837
  headers: {
@@ -42542,7 +40938,7 @@ export interface paths {
42542
40938
  patch?: never;
42543
40939
  trace?: never;
42544
40940
  };
42545
- '/api/overview/platform': {
40941
+ '/api/overview/casehandler/analytics': {
42546
40942
  parameters: {
42547
40943
  query?: never;
42548
40944
  header?: never;
@@ -42550,226 +40946,21 @@ export interface paths {
42550
40946
  cookie?: never;
42551
40947
  };
42552
40948
  /**
42553
- * Get platform overview
42554
- * @description Get complete platform-wide overview for admin/drift including aggregated stats across ALL users and accounts
40949
+ * Get casehandler analytics
40950
+ * @description Get contract cases analytics including time-series data for case creation, handling, and approval
42555
40951
  */
42556
40952
  get: {
42557
40953
  parameters: {
42558
- query?: never;
40954
+ query?: {
40955
+ /** @description Time period for analytics data */
40956
+ period?: '7d' | '30d' | '90d';
40957
+ };
42559
40958
  header?: never;
42560
40959
  path?: never;
42561
40960
  cookie?: never;
42562
40961
  };
42563
40962
  requestBody?: never;
42564
40963
  responses: {
42565
- /** @description Complete platform overview response for admin/drift */
42566
- 200: {
42567
- headers: {
42568
- [name: string]: unknown;
42569
- };
42570
- content: {
42571
- 'application/json': {
42572
- /** @description Complete platform overview data for admin/drift */
42573
- data: {
42574
- /** @description High-level summary metrics across the entire platform */
42575
- summary: {
42576
- /** @description Non-negative integer (0 or greater) */
42577
- totalEntities: number;
42578
- /** @description Non-negative integer (0 or greater) */
42579
- activeItems: number;
42580
- /** @description Non-negative integer (0 or greater) */
42581
- inProgressItems: number;
42582
- /** @description Non-negative integer (0 or greater) */
42583
- usersTotal: number;
42584
- /** @description Non-negative integer (0 or greater) */
42585
- usersActive30d: number;
42586
- };
42587
- /** @description Platform-wide stats for each entity type */
42588
- entities: {
42589
- jobs: {
42590
- byStatus: {
42591
- [key: string]: number;
42592
- };
42593
- totals: {
42594
- /** @description Non-negative integer (0 or greater) */
42595
- all: number;
42596
- /** @description Non-negative integer (0 or greater) */
42597
- active: number;
42598
- /** @description Non-negative integer (0 or greater) */
42599
- needsAction?: number;
42600
- /** @description Non-negative integer (0 or greater) */
42601
- inProgress?: number;
42602
- };
42603
- alerts?: {
42604
- type: 'info' | 'warning' | 'error' | 'action_required';
42605
- severity: 'low' | 'medium' | 'high';
42606
- /** @description Non-negative integer (0 or greater) */
42607
- count: number;
42608
- message: string;
42609
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42610
- status?: string;
42611
- }[];
42612
- };
42613
- applications: {
42614
- byStatus: {
42615
- [key: string]: number;
42616
- };
42617
- totals: {
42618
- /** @description Non-negative integer (0 or greater) */
42619
- all: number;
42620
- /** @description Non-negative integer (0 or greater) */
42621
- active: number;
42622
- /** @description Non-negative integer (0 or greater) */
42623
- needsAction?: number;
42624
- /** @description Non-negative integer (0 or greater) */
42625
- inProgress?: number;
42626
- };
42627
- alerts?: {
42628
- type: 'info' | 'warning' | 'error' | 'action_required';
42629
- severity: 'low' | 'medium' | 'high';
42630
- /** @description Non-negative integer (0 or greater) */
42631
- count: number;
42632
- message: string;
42633
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42634
- status?: string;
42635
- }[];
42636
- };
42637
- inquiries: {
42638
- byStatus: {
42639
- [key: string]: number;
42640
- };
42641
- totals: {
42642
- /** @description Non-negative integer (0 or greater) */
42643
- all: number;
42644
- /** @description Non-negative integer (0 or greater) */
42645
- active: number;
42646
- /** @description Non-negative integer (0 or greater) */
42647
- needsAction?: number;
42648
- /** @description Non-negative integer (0 or greater) */
42649
- inProgress?: number;
42650
- };
42651
- alerts?: {
42652
- type: 'info' | 'warning' | 'error' | 'action_required';
42653
- severity: 'low' | 'medium' | 'high';
42654
- /** @description Non-negative integer (0 or greater) */
42655
- count: number;
42656
- message: string;
42657
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42658
- status?: string;
42659
- }[];
42660
- };
42661
- invites: {
42662
- byStatus: {
42663
- [key: string]: number;
42664
- };
42665
- totals: {
42666
- /** @description Non-negative integer (0 or greater) */
42667
- all: number;
42668
- /** @description Non-negative integer (0 or greater) */
42669
- active: number;
42670
- /** @description Non-negative integer (0 or greater) */
42671
- needsAction?: number;
42672
- /** @description Non-negative integer (0 or greater) */
42673
- inProgress?: number;
42674
- };
42675
- alerts?: {
42676
- type: 'info' | 'warning' | 'error' | 'action_required';
42677
- severity: 'low' | 'medium' | 'high';
42678
- /** @description Non-negative integer (0 or greater) */
42679
- count: number;
42680
- message: string;
42681
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42682
- status?: string;
42683
- }[];
42684
- };
42685
- contracts: {
42686
- byStatus: {
42687
- [key: string]: number;
42688
- };
42689
- totals: {
42690
- /** @description Non-negative integer (0 or greater) */
42691
- all: number;
42692
- /** @description Non-negative integer (0 or greater) */
42693
- active: number;
42694
- /** @description Non-negative integer (0 or greater) */
42695
- needsAction?: number;
42696
- /** @description Non-negative integer (0 or greater) */
42697
- inProgress?: number;
42698
- };
42699
- alerts?: {
42700
- type: 'info' | 'warning' | 'error' | 'action_required';
42701
- severity: 'low' | 'medium' | 'high';
42702
- /** @description Non-negative integer (0 or greater) */
42703
- count: number;
42704
- message: string;
42705
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42706
- status?: string;
42707
- }[];
42708
- };
42709
- users: {
42710
- /** @description Non-negative integer (0 or greater) */
42711
- total_users: number;
42712
- /** @description Non-negative integer (0 or greater) */
42713
- active_users_30d: number;
42714
- /** @description Non-negative integer (0 or greater) */
42715
- active_users_7d: number;
42716
- /** @description Non-negative integer (0 or greater) */
42717
- active_users_1d: number;
42718
- /** @description Non-negative integer (0 or greater) */
42719
- new_users_30d: number;
42720
- /** @description Non-negative integer (0 or greater) */
42721
- new_users_7d: number;
42722
- /**
42723
- * Format: date-time
42724
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42725
- */
42726
- refreshed_at: string;
42727
- };
42728
- };
42729
- /** @description All platform alerts, sorted by priority */
42730
- aggregatedAlerts: {
42731
- type: 'info' | 'warning' | 'error' | 'action_required';
42732
- severity: 'low' | 'medium' | 'high';
42733
- /** @description Non-negative integer (0 or greater) */
42734
- count: number;
42735
- message: string;
42736
- entityType: 'job' | 'application' | 'inquiry' | 'invite' | 'contract';
42737
- status?: string;
42738
- }[];
42739
- };
42740
- metadata: {
42741
- /** @description Role context for the statistics query */
42742
- role: 'coordinator' | 'employer' | 'worker' | 'teamlead' | 'assistant' | 'case_manager' | 'applicant' | 'platform_admin';
42743
- /**
42744
- * Format: uuid
42745
- * @description UUID version 4 identifier
42746
- */
42747
- accountId?: string;
42748
- /**
42749
- * Format: uuid
42750
- * @description UUID version 4 identifier
42751
- */
42752
- userId?: string;
42753
- /**
42754
- * Format: date-time
42755
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42756
- */
42757
- queriedAt: string;
42758
- /** @description Whether the result was served from cache */
42759
- cached?: boolean;
42760
- /**
42761
- * Format: date-time
42762
- * @description ISO 8601 datetime format (YYYY-MM-DDTHH:mm:ss.sssZ)
42763
- */
42764
- cacheExpiresAt?: string;
42765
- /** @description List of entity types included in the overview */
42766
- entitiesIncluded: string[];
42767
- /** @description Total query time in milliseconds */
42768
- queryTimeMs?: number;
42769
- };
42770
- };
42771
- };
42772
- };
42773
40964
  /** @description Default Response */
42774
40965
  403: {
42775
40966
  headers: {
@@ -46659,80 +44850,6 @@ export interface paths {
46659
44850
  patch?: never;
46660
44851
  trace?: never;
46661
44852
  };
46662
- '/api/support/users/{id}/sessions': {
46663
- parameters: {
46664
- query?: never;
46665
- header?: never;
46666
- path?: never;
46667
- cookie?: never;
46668
- };
46669
- /**
46670
- * Get user sessions
46671
- * @description Get paginated session history for a user. Requires CASE_MANAGER role.
46672
- */
46673
- get: {
46674
- parameters: {
46675
- query?: {
46676
- limit?: number;
46677
- offset?: number;
46678
- };
46679
- header?: never;
46680
- path: {
46681
- /** @description User ID */
46682
- id: string;
46683
- };
46684
- cookie?: never;
46685
- };
46686
- requestBody?: never;
46687
- responses: {
46688
- /** @description Default Response */
46689
- 200: {
46690
- headers: {
46691
- [name: string]: unknown;
46692
- };
46693
- content: {
46694
- 'application/json': {
46695
- data: {
46696
- id: string;
46697
- user_id: string;
46698
- started_at: string;
46699
- ended_at?: string;
46700
- last_activity_at: string;
46701
- is_active: boolean;
46702
- ip_address?: string;
46703
- device_type?: string;
46704
- user_agent?: string;
46705
- }[];
46706
- pagination: {
46707
- limit: number;
46708
- offset: number;
46709
- total: number;
46710
- has_more: boolean;
46711
- };
46712
- };
46713
- };
46714
- };
46715
- /** @description Default Response */
46716
- 500: {
46717
- headers: {
46718
- [name: string]: unknown;
46719
- };
46720
- content: {
46721
- 'application/json': {
46722
- error: string;
46723
- };
46724
- };
46725
- };
46726
- };
46727
- };
46728
- put?: never;
46729
- post?: never;
46730
- delete?: never;
46731
- options?: never;
46732
- head?: never;
46733
- patch?: never;
46734
- trace?: never;
46735
- };
46736
44853
  '/api/support/users/{id}/deactivate': {
46737
44854
  parameters: {
46738
44855
  query?: never;