@uipath/uipath-typescript 1.3.3 → 1.3.5

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 (38) hide show
  1. package/dist/assets/index.cjs +8 -1
  2. package/dist/assets/index.mjs +8 -1
  3. package/dist/attachments/index.cjs +8 -1
  4. package/dist/attachments/index.mjs +8 -1
  5. package/dist/buckets/index.cjs +8 -1
  6. package/dist/buckets/index.mjs +8 -1
  7. package/dist/cases/index.cjs +8 -1
  8. package/dist/cases/index.mjs +8 -1
  9. package/dist/conversational-agent/index.cjs +8 -1
  10. package/dist/conversational-agent/index.d.ts +29 -2
  11. package/dist/conversational-agent/index.mjs +8 -1
  12. package/dist/core/index.cjs +1 -1
  13. package/dist/core/index.d.ts +1 -1
  14. package/dist/core/index.mjs +1 -1
  15. package/dist/document-understanding/index.cjs +257 -0
  16. package/dist/document-understanding/index.d.ts +1185 -0
  17. package/dist/document-understanding/index.mjs +255 -0
  18. package/dist/entities/index.cjs +277 -15
  19. package/dist/entities/index.d.ts +135 -0
  20. package/dist/entities/index.mjs +277 -15
  21. package/dist/feedback/index.cjs +8 -1
  22. package/dist/feedback/index.mjs +8 -1
  23. package/dist/index.cjs +578 -15
  24. package/dist/index.d.ts +1384 -9
  25. package/dist/index.mjs +580 -18
  26. package/dist/index.umd.js +578 -15
  27. package/dist/jobs/index.cjs +54 -1
  28. package/dist/jobs/index.d.ts +52 -0
  29. package/dist/jobs/index.mjs +54 -1
  30. package/dist/maestro-processes/index.cjs +8 -1
  31. package/dist/maestro-processes/index.mjs +8 -1
  32. package/dist/processes/index.cjs +8 -1
  33. package/dist/processes/index.mjs +8 -1
  34. package/dist/queues/index.cjs +8 -1
  35. package/dist/queues/index.mjs +8 -1
  36. package/dist/tasks/index.cjs +8 -1
  37. package/dist/tasks/index.mjs +8 -1
  38. package/package.json +12 -2
@@ -506,6 +506,8 @@ class ErrorFactory {
506
506
  }
507
507
 
508
508
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
509
+ const TRACEPARENT = 'traceparent';
510
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
509
511
  /**
510
512
  * Content type constants for HTTP requests/responses
511
513
  */
@@ -559,8 +561,13 @@ class ApiClient {
559
561
  if (isFormData) {
560
562
  delete defaultHeaders['Content-Type'];
561
563
  }
564
+ const traceId = crypto.randomUUID().replace(/-/g, '');
565
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
566
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
562
567
  const headers = {
563
568
  ...defaultHeaders,
569
+ [TRACEPARENT]: traceparentValue,
570
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
564
571
  ...options.headers
565
572
  };
566
573
  // Convert params to URLSearchParams
@@ -1677,6 +1684,13 @@ function createJobMethods(jobData, service) {
1677
1684
  throw new Error('Job folderId is undefined');
1678
1685
  return service.resume(jobData.key, jobData.folderId, options);
1679
1686
  },
1687
+ async restart() {
1688
+ if (!jobData.key)
1689
+ throw new Error('Job key is undefined');
1690
+ if (!jobData.folderId)
1691
+ throw new Error('Job folderId is undefined');
1692
+ return service.restart(jobData.key, jobData.folderId);
1693
+ },
1680
1694
  };
1681
1695
  }
1682
1696
  /**
@@ -1707,6 +1721,7 @@ const JOB_ENDPOINTS = {
1707
1721
  GET_BY_KEY: (identifier) => `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.GetByKey(identifier=${identifier})`,
1708
1722
  STOP: `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.StopJobs`,
1709
1723
  RESUME: `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.ResumeJob`,
1724
+ RESTART: `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.RestartJob`,
1710
1725
  };
1711
1726
  /**
1712
1727
  * Orchestrator Attachment Service Endpoints
@@ -1738,7 +1753,7 @@ const JobMap = {
1738
1753
  // Connection string placeholder that will be replaced during build
1739
1754
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1740
1755
  // SDK Version placeholder
1741
- const SDK_VERSION = "1.3.3";
1756
+ const SDK_VERSION = "1.3.5";
1742
1757
  const VERSION = "Version";
1743
1758
  const SERVICE = "Service";
1744
1759
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -2483,6 +2498,41 @@ class JobService extends FolderScopedService {
2483
2498
  }
2484
2499
  await this.post(JOB_ENDPOINTS.RESUME, body, { headers });
2485
2500
  }
2501
+ /**
2502
+ * Restarts a job in a final state (Successful, Faulted, or Stopped).
2503
+ *
2504
+ * Creates a **new** job execution from a previously successful, faulted, or stopped job.
2505
+ * The new job has its own unique `key`, starts in `Pending` state, and uses
2506
+ * the same process and input arguments as the original job.
2507
+ *
2508
+ * To monitor the new job's progress, poll with {@link getById}
2509
+ * using the returned job's key until the state reaches a final value.
2510
+ *
2511
+ * @param jobKey - The unique key (GUID) of the job to restart
2512
+ * @param folderId - The folder ID where the job resides
2513
+ * @returns Promise resolving to the new {@link JobGetResponse} with full job details
2514
+ *
2515
+ * @example
2516
+ * ```typescript
2517
+ * // Restart a faulted job
2518
+ * const newJob = await jobs.restart(<jobKey>, <folderId>);
2519
+ * console.log(newJob.state); // 'Pending'
2520
+ * console.log(newJob.key); // new job key (different from original)
2521
+ * ```
2522
+ */
2523
+ async restart(jobKey, folderId) {
2524
+ if (!jobKey) {
2525
+ throw new ValidationError({ message: 'jobKey is required for restart' });
2526
+ }
2527
+ if (!folderId) {
2528
+ throw new ValidationError({ message: 'folderId is required for restart' });
2529
+ }
2530
+ const [jobId] = await this.resolveJobKeys([jobKey], folderId);
2531
+ const headers = createHeaders({ [FOLDER_ID]: folderId });
2532
+ const response = await this.post(JOB_ENDPOINTS.RESTART, { jobId }, { headers });
2533
+ const rawJob = transformData(pascalToCamelCaseKeys(response.data), JobMap);
2534
+ return createJobWithMethods(rawJob, this);
2535
+ }
2486
2536
  /**
2487
2537
  * Downloads the output file content via the Attachments API.
2488
2538
  * 1. Fetches blob access info from the attachment using AttachmentService
@@ -2570,6 +2620,9 @@ __decorate([
2570
2620
  __decorate([
2571
2621
  track('Jobs.Resume')
2572
2622
  ], JobService.prototype, "resume", null);
2623
+ __decorate([
2624
+ track('Jobs.Restart')
2625
+ ], JobService.prototype, "restart", null);
2573
2626
 
2574
2627
  /**
2575
2628
  * Enum for job sub-state
@@ -832,6 +832,29 @@ interface JobServiceModel {
832
832
  * ```
833
833
  */
834
834
  resume(jobKey: string, folderId: number, options?: JobResumeOptions): Promise<void>;
835
+ /**
836
+ * Restarts a job in a final state (Successful, Faulted, or Stopped).
837
+ *
838
+ * Creates a **new** job execution from a previously successful, faulted, or stopped job.
839
+ * The new job has its own unique `key`, starts in `Pending` state, and uses
840
+ * the same process and input arguments as the original job.
841
+ *
842
+ * To monitor the new job's progress, poll with {@link getById}
843
+ * using the returned job's key until the state reaches a final value.
844
+ *
845
+ * @param jobKey - The unique key (GUID) of the job to restart
846
+ * @param folderId - The folder ID where the job resides
847
+ * @returns Promise resolving to the new {@link JobGetResponse} with full job details
848
+ *
849
+ * @example
850
+ * ```typescript
851
+ * // Restart a faulted job
852
+ * const newJob = await jobs.restart(<jobKey>, <folderId>);
853
+ * console.log(newJob.state); // 'Pending'
854
+ * console.log(newJob.key); // new job key (different from original)
855
+ * ```
856
+ */
857
+ restart(jobKey: string, folderId: number): Promise<JobGetResponse>;
835
858
  }
836
859
  /**
837
860
  * Methods available on job response objects.
@@ -884,6 +907,12 @@ interface JobMethods {
884
907
  * @returns Promise that resolves when the job is resumed successfully, or rejects on failure
885
908
  */
886
909
  resume(options?: JobResumeOptions): Promise<void>;
910
+ /**
911
+ * Restarts this job, creating a new execution with a new key.
912
+ *
913
+ * @returns Promise resolving to the new {@link JobGetResponse} with full job details
914
+ */
915
+ restart(): Promise<JobGetResponse>;
887
916
  }
888
917
  /**
889
918
  * Creates a job response with bound methods.
@@ -1063,6 +1092,29 @@ declare class JobService extends FolderScopedService implements JobServiceModel
1063
1092
  * ```
1064
1093
  */
1065
1094
  resume(jobKey: string, folderId: number, options?: JobResumeOptions): Promise<void>;
1095
+ /**
1096
+ * Restarts a job in a final state (Successful, Faulted, or Stopped).
1097
+ *
1098
+ * Creates a **new** job execution from a previously successful, faulted, or stopped job.
1099
+ * The new job has its own unique `key`, starts in `Pending` state, and uses
1100
+ * the same process and input arguments as the original job.
1101
+ *
1102
+ * To monitor the new job's progress, poll with {@link getById}
1103
+ * using the returned job's key until the state reaches a final value.
1104
+ *
1105
+ * @param jobKey - The unique key (GUID) of the job to restart
1106
+ * @param folderId - The folder ID where the job resides
1107
+ * @returns Promise resolving to the new {@link JobGetResponse} with full job details
1108
+ *
1109
+ * @example
1110
+ * ```typescript
1111
+ * // Restart a faulted job
1112
+ * const newJob = await jobs.restart(<jobKey>, <folderId>);
1113
+ * console.log(newJob.state); // 'Pending'
1114
+ * console.log(newJob.key); // new job key (different from original)
1115
+ * ```
1116
+ */
1117
+ restart(jobKey: string, folderId: number): Promise<JobGetResponse>;
1066
1118
  /**
1067
1119
  * Downloads the output file content via the Attachments API.
1068
1120
  * 1. Fetches blob access info from the attachment using AttachmentService
@@ -504,6 +504,8 @@ class ErrorFactory {
504
504
  }
505
505
 
506
506
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
507
+ const TRACEPARENT = 'traceparent';
508
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
507
509
  /**
508
510
  * Content type constants for HTTP requests/responses
509
511
  */
@@ -557,8 +559,13 @@ class ApiClient {
557
559
  if (isFormData) {
558
560
  delete defaultHeaders['Content-Type'];
559
561
  }
562
+ const traceId = crypto.randomUUID().replace(/-/g, '');
563
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
564
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
560
565
  const headers = {
561
566
  ...defaultHeaders,
567
+ [TRACEPARENT]: traceparentValue,
568
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
562
569
  ...options.headers
563
570
  };
564
571
  // Convert params to URLSearchParams
@@ -1675,6 +1682,13 @@ function createJobMethods(jobData, service) {
1675
1682
  throw new Error('Job folderId is undefined');
1676
1683
  return service.resume(jobData.key, jobData.folderId, options);
1677
1684
  },
1685
+ async restart() {
1686
+ if (!jobData.key)
1687
+ throw new Error('Job key is undefined');
1688
+ if (!jobData.folderId)
1689
+ throw new Error('Job folderId is undefined');
1690
+ return service.restart(jobData.key, jobData.folderId);
1691
+ },
1678
1692
  };
1679
1693
  }
1680
1694
  /**
@@ -1705,6 +1719,7 @@ const JOB_ENDPOINTS = {
1705
1719
  GET_BY_KEY: (identifier) => `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.GetByKey(identifier=${identifier})`,
1706
1720
  STOP: `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.StopJobs`,
1707
1721
  RESUME: `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.ResumeJob`,
1722
+ RESTART: `${ORCHESTRATOR_BASE}/odata/Jobs/UiPath.Server.Configuration.OData.RestartJob`,
1708
1723
  };
1709
1724
  /**
1710
1725
  * Orchestrator Attachment Service Endpoints
@@ -1736,7 +1751,7 @@ const JobMap = {
1736
1751
  // Connection string placeholder that will be replaced during build
1737
1752
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1738
1753
  // SDK Version placeholder
1739
- const SDK_VERSION = "1.3.3";
1754
+ const SDK_VERSION = "1.3.5";
1740
1755
  const VERSION = "Version";
1741
1756
  const SERVICE = "Service";
1742
1757
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -2481,6 +2496,41 @@ class JobService extends FolderScopedService {
2481
2496
  }
2482
2497
  await this.post(JOB_ENDPOINTS.RESUME, body, { headers });
2483
2498
  }
2499
+ /**
2500
+ * Restarts a job in a final state (Successful, Faulted, or Stopped).
2501
+ *
2502
+ * Creates a **new** job execution from a previously successful, faulted, or stopped job.
2503
+ * The new job has its own unique `key`, starts in `Pending` state, and uses
2504
+ * the same process and input arguments as the original job.
2505
+ *
2506
+ * To monitor the new job's progress, poll with {@link getById}
2507
+ * using the returned job's key until the state reaches a final value.
2508
+ *
2509
+ * @param jobKey - The unique key (GUID) of the job to restart
2510
+ * @param folderId - The folder ID where the job resides
2511
+ * @returns Promise resolving to the new {@link JobGetResponse} with full job details
2512
+ *
2513
+ * @example
2514
+ * ```typescript
2515
+ * // Restart a faulted job
2516
+ * const newJob = await jobs.restart(<jobKey>, <folderId>);
2517
+ * console.log(newJob.state); // 'Pending'
2518
+ * console.log(newJob.key); // new job key (different from original)
2519
+ * ```
2520
+ */
2521
+ async restart(jobKey, folderId) {
2522
+ if (!jobKey) {
2523
+ throw new ValidationError({ message: 'jobKey is required for restart' });
2524
+ }
2525
+ if (!folderId) {
2526
+ throw new ValidationError({ message: 'folderId is required for restart' });
2527
+ }
2528
+ const [jobId] = await this.resolveJobKeys([jobKey], folderId);
2529
+ const headers = createHeaders({ [FOLDER_ID]: folderId });
2530
+ const response = await this.post(JOB_ENDPOINTS.RESTART, { jobId }, { headers });
2531
+ const rawJob = transformData(pascalToCamelCaseKeys(response.data), JobMap);
2532
+ return createJobWithMethods(rawJob, this);
2533
+ }
2484
2534
  /**
2485
2535
  * Downloads the output file content via the Attachments API.
2486
2536
  * 1. Fetches blob access info from the attachment using AttachmentService
@@ -2568,6 +2618,9 @@ __decorate([
2568
2618
  __decorate([
2569
2619
  track('Jobs.Resume')
2570
2620
  ], JobService.prototype, "resume", null);
2621
+ __decorate([
2622
+ track('Jobs.Restart')
2623
+ ], JobService.prototype, "restart", null);
2571
2624
 
2572
2625
  /**
2573
2626
  * Enum for job sub-state
@@ -507,6 +507,8 @@ class ErrorFactory {
507
507
 
508
508
  const FOLDER_KEY = 'X-UIPATH-FolderKey';
509
509
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
510
+ const TRACEPARENT = 'traceparent';
511
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
510
512
  /**
511
513
  * Content type constants for HTTP requests/responses
512
514
  */
@@ -560,8 +562,13 @@ class ApiClient {
560
562
  if (isFormData) {
561
563
  delete defaultHeaders['Content-Type'];
562
564
  }
565
+ const traceId = crypto.randomUUID().replace(/-/g, '');
566
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
567
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
563
568
  const headers = {
564
569
  ...defaultHeaders,
570
+ [TRACEPARENT]: traceparentValue,
571
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
565
572
  ...options.headers
566
573
  };
567
574
  // Convert params to URLSearchParams
@@ -1735,7 +1742,7 @@ class BpmnHelpers {
1735
1742
  // Connection string placeholder that will be replaced during build
1736
1743
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1737
1744
  // SDK Version placeholder
1738
- const SDK_VERSION = "1.3.3";
1745
+ const SDK_VERSION = "1.3.5";
1739
1746
  const VERSION = "Version";
1740
1747
  const SERVICE = "Service";
1741
1748
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -505,6 +505,8 @@ class ErrorFactory {
505
505
 
506
506
  const FOLDER_KEY = 'X-UIPATH-FolderKey';
507
507
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
508
+ const TRACEPARENT = 'traceparent';
509
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
508
510
  /**
509
511
  * Content type constants for HTTP requests/responses
510
512
  */
@@ -558,8 +560,13 @@ class ApiClient {
558
560
  if (isFormData) {
559
561
  delete defaultHeaders['Content-Type'];
560
562
  }
563
+ const traceId = crypto.randomUUID().replace(/-/g, '');
564
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
565
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
561
566
  const headers = {
562
567
  ...defaultHeaders,
568
+ [TRACEPARENT]: traceparentValue,
569
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
563
570
  ...options.headers
564
571
  };
565
572
  // Convert params to URLSearchParams
@@ -1733,7 +1740,7 @@ class BpmnHelpers {
1733
1740
  // Connection string placeholder that will be replaced during build
1734
1741
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1735
1742
  // SDK Version placeholder
1736
- const SDK_VERSION = "1.3.3";
1743
+ const SDK_VERSION = "1.3.5";
1737
1744
  const VERSION = "Version";
1738
1745
  const SERVICE = "Service";
1739
1746
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -506,6 +506,8 @@ class ErrorFactory {
506
506
  }
507
507
 
508
508
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
509
+ const TRACEPARENT = 'traceparent';
510
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
509
511
  /**
510
512
  * Content type constants for HTTP requests/responses
511
513
  */
@@ -559,8 +561,13 @@ class ApiClient {
559
561
  if (isFormData) {
560
562
  delete defaultHeaders['Content-Type'];
561
563
  }
564
+ const traceId = crypto.randomUUID().replace(/-/g, '');
565
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
566
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
562
567
  const headers = {
563
568
  ...defaultHeaders,
569
+ [TRACEPARENT]: traceparentValue,
570
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
564
571
  ...options.headers
565
572
  };
566
573
  // Convert params to URLSearchParams
@@ -1715,7 +1722,7 @@ const PROCESS_ENDPOINTS = {
1715
1722
  // Connection string placeholder that will be replaced during build
1716
1723
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1717
1724
  // SDK Version placeholder
1718
- const SDK_VERSION = "1.3.3";
1725
+ const SDK_VERSION = "1.3.5";
1719
1726
  const VERSION = "Version";
1720
1727
  const SERVICE = "Service";
1721
1728
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -504,6 +504,8 @@ class ErrorFactory {
504
504
  }
505
505
 
506
506
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
507
+ const TRACEPARENT = 'traceparent';
508
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
507
509
  /**
508
510
  * Content type constants for HTTP requests/responses
509
511
  */
@@ -557,8 +559,13 @@ class ApiClient {
557
559
  if (isFormData) {
558
560
  delete defaultHeaders['Content-Type'];
559
561
  }
562
+ const traceId = crypto.randomUUID().replace(/-/g, '');
563
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
564
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
560
565
  const headers = {
561
566
  ...defaultHeaders,
567
+ [TRACEPARENT]: traceparentValue,
568
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
562
569
  ...options.headers
563
570
  };
564
571
  // Convert params to URLSearchParams
@@ -1713,7 +1720,7 @@ const PROCESS_ENDPOINTS = {
1713
1720
  // Connection string placeholder that will be replaced during build
1714
1721
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1715
1722
  // SDK Version placeholder
1716
- const SDK_VERSION = "1.3.3";
1723
+ const SDK_VERSION = "1.3.5";
1717
1724
  const VERSION = "Version";
1718
1725
  const SERVICE = "Service";
1719
1726
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -506,6 +506,8 @@ class ErrorFactory {
506
506
  }
507
507
 
508
508
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
509
+ const TRACEPARENT = 'traceparent';
510
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
509
511
  /**
510
512
  * Content type constants for HTTP requests/responses
511
513
  */
@@ -559,8 +561,13 @@ class ApiClient {
559
561
  if (isFormData) {
560
562
  delete defaultHeaders['Content-Type'];
561
563
  }
564
+ const traceId = crypto.randomUUID().replace(/-/g, '');
565
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
566
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
562
567
  const headers = {
563
568
  ...defaultHeaders,
569
+ [TRACEPARENT]: traceparentValue,
570
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
564
571
  ...options.headers
565
572
  };
566
573
  // Convert params to URLSearchParams
@@ -1679,7 +1686,7 @@ const QueueMap = {
1679
1686
  // Connection string placeholder that will be replaced during build
1680
1687
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1681
1688
  // SDK Version placeholder
1682
- const SDK_VERSION = "1.3.3";
1689
+ const SDK_VERSION = "1.3.5";
1683
1690
  const VERSION = "Version";
1684
1691
  const SERVICE = "Service";
1685
1692
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -504,6 +504,8 @@ class ErrorFactory {
504
504
  }
505
505
 
506
506
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
507
+ const TRACEPARENT = 'traceparent';
508
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
507
509
  /**
508
510
  * Content type constants for HTTP requests/responses
509
511
  */
@@ -557,8 +559,13 @@ class ApiClient {
557
559
  if (isFormData) {
558
560
  delete defaultHeaders['Content-Type'];
559
561
  }
562
+ const traceId = crypto.randomUUID().replace(/-/g, '');
563
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
564
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
560
565
  const headers = {
561
566
  ...defaultHeaders,
567
+ [TRACEPARENT]: traceparentValue,
568
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
562
569
  ...options.headers
563
570
  };
564
571
  // Convert params to URLSearchParams
@@ -1677,7 +1684,7 @@ const QueueMap = {
1677
1684
  // Connection string placeholder that will be replaced during build
1678
1685
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
1679
1686
  // SDK Version placeholder
1680
- const SDK_VERSION = "1.3.3";
1687
+ const SDK_VERSION = "1.3.5";
1681
1688
  const VERSION = "Version";
1682
1689
  const SERVICE = "Service";
1683
1690
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -278,7 +278,7 @@ class NetworkError extends UiPathError {
278
278
  // Connection string placeholder that will be replaced during build
279
279
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
280
280
  // SDK Version placeholder
281
- const SDK_VERSION = "1.3.3";
281
+ const SDK_VERSION = "1.3.5";
282
282
  const VERSION = "Version";
283
283
  const SERVICE = "Service";
284
284
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -797,6 +797,8 @@ const BUCKET_TOKEN_PARAMS = {
797
797
  };
798
798
 
799
799
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
800
+ const TRACEPARENT = 'traceparent';
801
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
800
802
  /**
801
803
  * Content type constants for HTTP requests/responses
802
804
  */
@@ -1767,8 +1769,13 @@ class ApiClient {
1767
1769
  if (isFormData) {
1768
1770
  delete defaultHeaders['Content-Type'];
1769
1771
  }
1772
+ const traceId = crypto.randomUUID().replace(/-/g, '');
1773
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
1774
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
1770
1775
  const headers = {
1771
1776
  ...defaultHeaders,
1777
+ [TRACEPARENT]: traceparentValue,
1778
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
1772
1779
  ...options.headers
1773
1780
  };
1774
1781
  // Convert params to URLSearchParams
@@ -276,7 +276,7 @@ class NetworkError extends UiPathError {
276
276
  // Connection string placeholder that will be replaced during build
277
277
  const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
278
278
  // SDK Version placeholder
279
- const SDK_VERSION = "1.3.3";
279
+ const SDK_VERSION = "1.3.5";
280
280
  const VERSION = "Version";
281
281
  const SERVICE = "Service";
282
282
  const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
@@ -795,6 +795,8 @@ const BUCKET_TOKEN_PARAMS = {
795
795
  };
796
796
 
797
797
  const FOLDER_ID = 'X-UIPATH-OrganizationUnitId';
798
+ const TRACEPARENT = 'traceparent';
799
+ const UIPATH_TRACEPARENT_ID = 'x-uipath-traceparent-id';
798
800
  /**
799
801
  * Content type constants for HTTP requests/responses
800
802
  */
@@ -1765,8 +1767,13 @@ class ApiClient {
1765
1767
  if (isFormData) {
1766
1768
  delete defaultHeaders['Content-Type'];
1767
1769
  }
1770
+ const traceId = crypto.randomUUID().replace(/-/g, '');
1771
+ const spanId = crypto.randomUUID().replace(/-/g, '').slice(0, 16);
1772
+ const traceparentValue = `00-${traceId}-${spanId}-01`;
1768
1773
  const headers = {
1769
1774
  ...defaultHeaders,
1775
+ [TRACEPARENT]: traceparentValue,
1776
+ [UIPATH_TRACEPARENT_ID]: traceparentValue,
1770
1777
  ...options.headers
1771
1778
  };
1772
1779
  // Convert params to URLSearchParams
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@uipath/uipath-typescript",
3
- "version": "1.3.3",
3
+ "version": "1.3.5",
4
4
  "description": "UiPath TypeScript SDK",
5
5
  "license": "MIT",
6
6
  "keywords": [
@@ -155,6 +155,16 @@
155
155
  "types": "./dist/feedback/index.d.ts",
156
156
  "default": "./dist/feedback/index.cjs"
157
157
  }
158
+ },
159
+ "./document-understanding": {
160
+ "import": {
161
+ "types": "./dist/document-understanding/index.d.ts",
162
+ "default": "./dist/document-understanding/index.mjs"
163
+ },
164
+ "require": {
165
+ "types": "./dist/document-understanding/index.d.ts",
166
+ "default": "./dist/document-understanding/index.cjs"
167
+ }
158
168
  }
159
169
  },
160
170
  "files": [
@@ -205,7 +215,7 @@
205
215
  "dotenv": "^17.2.0",
206
216
  "oxlint": "^1.43.0",
207
217
  "rimraf": "^6.0.1",
208
- "rollup": "^4.59.1",
218
+ "rollup": "^4.60.2",
209
219
  "rollup-plugin-dts": "^6.1.0",
210
220
  "tslib": "^2.8.1",
211
221
  "typedoc": "^0.28.13",