@alfresco/js-api 10.2.0-31151847596 → 10.2.0-31162511335

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfresco/js-api",
3
- "version": "10.2.0-31151847596",
3
+ "version": "10.2.0-31162511335",
4
4
  "license": "Apache-2.0",
5
5
  "description": "JavaScript client library for the Alfresco REST API",
6
6
  "author": "Hyland Software, Inc. and its affiliates",
@@ -185,5 +185,17 @@ export class ContentApi extends BaseApi {
185
185
  }
186
186
  });
187
187
  }
188
+ getProcessesAndTasksOnContentBatch(sourceIds, source, size, page) {
189
+ throwIfNotDefined(sourceIds, 'sourceIds');
190
+ throwIfNotDefined(source, 'source');
191
+ if (sourceIds.length > ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT) {
192
+ throw new Error(`sourceIds length exceeds the maximum batch size of ${ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT}`);
193
+ }
194
+ return this.post({
195
+ path: '/api/enterprise/document-runtime',
196
+ bodyParam: { sourceIds, source, size, page }
197
+ });
198
+ }
188
199
  }
200
+ ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT = 500;
189
201
  //# sourceMappingURL=../../../../../../../../lib/js-api/src/api/activiti-rest-api/api/content.api.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"content.api.js","sourceRoot":"","sources":["content.api.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACH,4BAA4B,EAC5B,wDAAwD,EAE3D,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AACrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAKpD,MAAM,OAAO,UAAW,SAAQ,OAAO;IASnC,qCAAqC,CACjC,iBAAyB,EACzB,cAAkD,EAClD,IAAqC;QAErC,iBAAiB,CAAC,i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,wDAAwD;SACvE,CAAC,CAAC;IACP,CAAC;IAWD,6BAA6B,CACzB,QAAgB,EAChB,MAAc,EACd,IAAa,EACb,IAAa;QAEb,iBAAiB,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC;QACxC,iBAAiB,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;QAEpC,OAAO,IAAI,CAAC,GAAG,CAAC;YACZ,IAAI,EAAE,kCAAkC;YACxC,WAAW,EAAE;gBACT,QAAQ;gBACR,MAAM;gBACN,IAAI;gBACJ,IAAI;aACP;SACJ,CAAC,CAAC;IACP,CAAC;CACJ","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n RelatedContentRepresentation,\n ResultListDataRepresentationRelatedContentRepresentation,\n ResultListDataRepresentationRelatedProcessTask\n} from '../model';\nimport { BaseApi } from './base.api';\nimport { throwIfNotDefined } from '../../../assert';\n\n/**\n * Content service.\n */\nexport class ContentApi extends BaseApi {\n /**\n * Attach existing content to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnProcessInstance(\n processInstanceId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/raw-content',\n pathParams,\n formParams,\n queryParams: opts,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Attach existing content to a task\n *\n * @param taskId taskId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnTask(\n taskId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n const pathParams = {\n taskId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/raw-content',\n pathParams,\n queryParams: opts,\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Upload content and create a local representation\n *\n * @param file file\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRawRelatedContent(file: any): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(file, 'file');\n\n const formParams = {\n file\n };\n\n return this.post({\n path: '/api/enterprise/content/raw',\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Create a local representation of content from a remote repository\n *\n * @param relatedContent relatedContent\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRelatedContent(relatedContent: RelatedContentRepresentation): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n return this.post({\n path: '/api/enterprise/content',\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Remove a local content representation\n *\n * @param contentId contentId\n * @return Promise<{}>\n */\n deleteContent(contentId: number): Promise<void> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.delete({\n path: '/api/enterprise/content/{contentId}',\n pathParams\n });\n }\n\n /**\n * Get a local content representation\n *\n * @param contentId contentId\n * @return Promise<RelatedContentRepresentation>\n */\n getContent(contentId: number): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}',\n pathParams,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Get content Raw URL for the given contentId\n *\n * @param contentId contentId\n */\n getRawContentUrl(contentId: number): string {\n return `${this.apiClient.basePath}/api/enterprise/content/${contentId}/raw`;\n }\n\n /**\n * Stream content rendition\n *\n * @param contentId contentId\n * @param renditionType renditionType\n * @return Promise<{}>\n */\n getRawContent(contentId: number, renditionType?: string): Promise<any> {\n throwIfNotDefined(contentId, 'contentId');\n\n if (renditionType) {\n const pathParams = {\n contentId,\n renditionType\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/rendition/{renditionType}',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n } else {\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/raw',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n }\n }\n\n /**\n * List content attached to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForProcessInstance(\n processInstanceId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n return this.get({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * List content attached to a task\n *\n * @param taskId taskId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForTask(\n taskId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n\n const pathParams = {\n taskId\n };\n\n return this.get({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * Lists processes and tasks on workflow started with provided document\n *\n * @param sourceId - id of the document that workflow or task has been started with\n * @param source - source of the document that workflow or task has been started with\n * @param size - size of the entries to get\n * @param page - page number\n * @return Promise<ResultListDataRepresentationRelatedProcessTask>\n */\n getProcessesAndTasksOnContent(\n sourceId: string,\n source: string,\n size?: number,\n page?: number\n ): Promise<ResultListDataRepresentationRelatedProcessTask> {\n throwIfNotDefined(sourceId, 'sourceId');\n throwIfNotDefined(source, 'source');\n\n return this.get({\n path: '/api/enterprise/document-runtime',\n queryParams: {\n sourceId,\n source,\n size,\n page\n }\n });\n }\n}\n"]}
1
+ {"version":3,"file":"content.api.js","sourceRoot":"","sources":["content.api.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,OAAO,EACH,4BAA4B,EAC5B,wDAAwD,EAE3D,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AACrC,OAAO,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAKpD,MAAM,OAAO,UAAW,SAAQ,OAAO;IAcnC,qCAAqC,CACjC,iBAAyB,EACzB,cAAkD,EAClD,IAAqC;QAErC,iBAAiB,C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,EAAE,wDAAwD;SACvE,CAAC,CAAC;IACP,CAAC;IAWD,6BAA6B,CACzB,QAAgB,EAChB,MAAc,EACd,IAAa,EACb,IAAa;QAEb,iBAAiB,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC;QACxC,iBAAiB,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;QAEpC,OAAO,IAAI,CAAC,GAAG,CAAC;YACZ,IAAI,EAAE,kCAAkC;YACxC,WAAW,EAAE;gBACT,QAAQ;gBACR,MAAM;gBACN,IAAI;gBACJ,IAAI;aACP;SACJ,CAAC,CAAC;IACP,CAAC;IAaD,kCAAkC,CAC9B,SAAmB,EACnB,MAAc,EACd,IAAa,EACb,IAAa;QAEb,iBAAiB,CAAC,SAAS,EAAE,WAAW,CAAC,CAAC;QAC1C,iBAAiB,CAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;QAEpC,IAAI,SAAS,CAAC,MAAM,GAAG,UAAU,CAAC,iCAAiC,EAAE,CAAC;YAClE,MAAM,IAAI,KAAK,CAAC,sDAAsD,UAAU,CAAC,iCAAiC,EAAE,CAAC,CAAC;QAC1H,CAAC;QAED,OAAO,IAAI,CAAC,IAAI,CAAC;YACb,IAAI,EAAE,kCAAkC;YACxC,SAAS,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE;SAC/C,CAAC,CAAC;IACP,CAAC;;AAlUe,4CAAiC,GAAG,GAAG,CAAC","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n RelatedContentRepresentation,\n ResultListDataRepresentationRelatedContentRepresentation,\n ResultListDataRepresentationRelatedProcessTask\n} from '../model';\nimport { BaseApi } from './base.api';\nimport { throwIfNotDefined } from '../../../assert';\n\n/**\n * Content service.\n */\nexport class ContentApi extends BaseApi {\n /**\n * Maximum number of source document ids accepted by the batch document-runtime endpoint in a single request.\n */\n static readonly DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT = 500;\n\n /**\n * Attach existing content to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnProcessInstance(\n processInstanceId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/raw-content',\n pathParams,\n formParams,\n queryParams: opts,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Attach existing content to a task\n *\n * @param taskId taskId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnTask(\n taskId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n const pathParams = {\n taskId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/raw-content',\n pathParams,\n queryParams: opts,\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Upload content and create a local representation\n *\n * @param file file\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRawRelatedContent(file: any): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(file, 'file');\n\n const formParams = {\n file\n };\n\n return this.post({\n path: '/api/enterprise/content/raw',\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Create a local representation of content from a remote repository\n *\n * @param relatedContent relatedContent\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRelatedContent(relatedContent: RelatedContentRepresentation): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n return this.post({\n path: '/api/enterprise/content',\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Remove a local content representation\n *\n * @param contentId contentId\n * @return Promise<{}>\n */\n deleteContent(contentId: number): Promise<void> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.delete({\n path: '/api/enterprise/content/{contentId}',\n pathParams\n });\n }\n\n /**\n * Get a local content representation\n *\n * @param contentId contentId\n * @return Promise<RelatedContentRepresentation>\n */\n getContent(contentId: number): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}',\n pathParams,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Get content Raw URL for the given contentId\n *\n * @param contentId contentId\n */\n getRawContentUrl(contentId: number): string {\n return `${this.apiClient.basePath}/api/enterprise/content/${contentId}/raw`;\n }\n\n /**\n * Stream content rendition\n *\n * @param contentId contentId\n * @param renditionType renditionType\n * @return Promise<{}>\n */\n getRawContent(contentId: number, renditionType?: string): Promise<any> {\n throwIfNotDefined(contentId, 'contentId');\n\n if (renditionType) {\n const pathParams = {\n contentId,\n renditionType\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/rendition/{renditionType}',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n } else {\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/raw',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n }\n }\n\n /**\n * List content attached to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForProcessInstance(\n processInstanceId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n return this.get({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * List content attached to a task\n *\n * @param taskId taskId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForTask(\n taskId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n\n const pathParams = {\n taskId\n };\n\n return this.get({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * Lists processes and tasks on workflow started with provided document\n *\n * @param sourceId - id of the document that workflow or task has been started with\n * @param source - source of the document that workflow or task has been started with\n * @param size - size of the entries to get\n * @param page - page number\n * @return Promise<ResultListDataRepresentationRelatedProcessTask>\n */\n getProcessesAndTasksOnContent(\n sourceId: string,\n source: string,\n size?: number,\n page?: number\n ): Promise<ResultListDataRepresentationRelatedProcessTask> {\n throwIfNotDefined(sourceId, 'sourceId');\n throwIfNotDefined(source, 'source');\n\n return this.get({\n path: '/api/enterprise/document-runtime',\n queryParams: {\n sourceId,\n source,\n size,\n page\n }\n });\n }\n\n /**\n * Batch variant of getProcessesAndTasksOnContent. Accepts multiple source document ids\n * in one request (up to 500) and returns the related processes and tasks for all of them.\n *\n * @param sourceIds - ids of the documents to query process participation for (up to 500)\n * @param source - source of the documents that workflows or tasks have been started with\n * @param size - size of the entries to get\n * @param page - page number\n * @return Promise<ResultListDataRepresentationRelatedProcessTask>\n * @throws {Error} if sourceIds exceeds DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT\n */\n getProcessesAndTasksOnContentBatch(\n sourceIds: string[],\n source: string,\n size?: number,\n page?: number\n ): Promise<ResultListDataRepresentationRelatedProcessTask> {\n throwIfNotDefined(sourceIds, 'sourceIds');\n throwIfNotDefined(source, 'source');\n\n if (sourceIds.length > ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT) {\n throw new Error(`sourceIds length exceeds the maximum batch size of ${ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT}`);\n }\n\n return this.post({\n path: '/api/enterprise/document-runtime',\n bodyParam: { sourceIds, source, size, page }\n });\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"relatedProcessTask.js","sourceRoot":"","sources":["relatedProcessTask.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport interface RelatedProcessTask {\n processId?: string;\n taskId?: string;\n}\n"]}
1
+ {"version":3,"file":"relatedProcessTask.js","sourceRoot":"","sources":["relatedProcessTask.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport interface RelatedProcessTask {\n processId?: string;\n taskId?: string;\n sourceId?: string;\n}\n"]}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfresco/js-api",
3
- "version": "10.2.0-31151847596",
3
+ "version": "10.2.0-31162511335",
4
4
  "license": "Apache-2.0",
5
5
  "description": "JavaScript client library for the Alfresco REST API",
6
6
  "author": "Hyland Software, Inc. and its affiliates",
@@ -188,6 +188,18 @@ class ContentApi extends base_api_1.BaseApi {
188
188
  }
189
189
  });
190
190
  }
191
+ getProcessesAndTasksOnContentBatch(sourceIds, source, size, page) {
192
+ (0, assert_1.throwIfNotDefined)(sourceIds, 'sourceIds');
193
+ (0, assert_1.throwIfNotDefined)(source, 'source');
194
+ if (sourceIds.length > ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT) {
195
+ throw new Error(`sourceIds length exceeds the maximum batch size of ${ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT}`);
196
+ }
197
+ return this.post({
198
+ path: '/api/enterprise/document-runtime',
199
+ bodyParam: { sourceIds, source, size, page }
200
+ });
201
+ }
191
202
  }
192
203
  exports.ContentApi = ContentApi;
204
+ ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT = 500;
193
205
  //# sourceMappingURL=../../../../../../../lib/js-api/src/api/activiti-rest-api/api/content.api.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"content.api.js","sourceRoot":"","sources":["content.api.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG;;;AAEH,oCAIkB;AAClB,yCAAqC;AACrC,4CAAoD;AAKpD,MAAa,UAAW,SAAQ,kBAAO;IASnC,qCAAqC,CACjC,iBAAyB,EACzB,cAAkD,EAClD,IAAqC;QAErC,IAAA,0BAAiB,EAAC,iBAAiB,EAAE,mBAAmB,CAAC,CAAC;QAC1D,IAAA,0BAAiB,EAAC,cAAc,EAAE,gBAAgB,CAAC,CAAC;QAEpD,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAElB,MAAM,UAAU,GAAG;YACf,iBAAiB;SACpB,CAAC;QAEF,IAAI,cAAc,YAAY,oCAA4B,EAAE,CAAC;YACzD,OAAO,IAAI,CAAC,IAAI,CAAC;gBACb,IAAI,EAAE,+DAA+D;gBACrE,UAAU;gBACV,WAAW,EAAE,IAAI;gBACjB,SAAS,EAAE,cAAc;gBACzB,UAAU,EAAE,oCAA4B;aAC3C,CAAC,CAAC;QACP,CAAC;aAAM,CAAC;YACJ,MAAM,UAAU,GAAG;gBACf,IAAI,EAAE,cAAc;aACvB,CAAC;YAEF,OAAO,IAAI,CAAC,IAAI,CAAC;gBACb,IAAI,EAAE,mEAAmE;gBACzE,UAAU;gBACV,UAAU;gBACV,WAAW,EAAE,IAAI;gBACjB,YAAY,EAAE,CAAC,qBAAqB,CAAC;gBACrC,UAAU,EAAE,oCAA4B;aAC3C,CAAC,CAAC;QACP,CAAC;IACL,CAAC;IAUD,0BAA0B,CACtB,MAAc,EACd,cAAkD,EAClD,IAAqC;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AiB,EAAE,mBAAmB,CAAC,CAAC;QAE1D,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAElB,MAAM,UAAU,GAAG;YACf,iBAAiB;SACpB,CAAC;QAEF,OAAO,IAAI,CAAC,GAAG,CAAC;YACZ,IAAI,EAAE,+DAA+D;YACrE,UAAU;YACV,WAAW,EAAE,IAAI;YACjB,UAAU,EAAE,gEAAwD;SACvE,CAAC,CAAC;IACP,CAAC;IASD,wBAAwB,CACpB,MAAc,EACd,IAAqC;QAErC,IAAA,0BAAiB,EAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;QAEpC,MAAM,UAAU,GAAG;YACf,MAAM;SACT,CAAC;QAEF,OAAO,IAAI,CAAC,GAAG,CAAC;YACZ,IAAI,EAAE,wCAAwC;YAC9C,UAAU;YACV,WAAW,EAAE,IAAI;YACjB,UAAU,EAAE,gEAAwD;SACvE,CAAC,CAAC;IACP,CAAC;IAWD,6BAA6B,CACzB,QAAgB,EAChB,MAAc,EACd,IAAa,EACb,IAAa;QAEb,IAAA,0BAAiB,EAAC,QAAQ,EAAE,UAAU,CAAC,CAAC;QACxC,IAAA,0BAAiB,EAAC,MAAM,EAAE,QAAQ,CAAC,CAAC;QAEpC,OAAO,IAAI,CAAC,GAAG,CAAC;YACZ,IAAI,EAAE,kCAAkC;YACxC,WAAW,EAAE;gBACT,QAAQ;gBACR,MAAM;gBACN,IAAI;gBACJ,IAAI;aACP;SACJ,CAAC,CAAC;IACP,CAAC;CACJ;AApSD,gCAoSC","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n RelatedContentRepresentation,\n ResultListDataRepresentationRelatedContentRepresentation,\n ResultListDataRepresentationRelatedProcessTask\n} from '../model';\nimport { BaseApi } from './base.api';\nimport { throwIfNotDefined } from '../../../assert';\n\n/**\n * Content service.\n */\nexport class ContentApi extends BaseApi {\n /**\n * Attach existing content to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnProcessInstance(\n processInstanceId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/raw-content',\n pathParams,\n formParams,\n queryParams: opts,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Attach existing content to a task\n *\n * @param taskId taskId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnTask(\n taskId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n const pathParams = {\n taskId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/raw-content',\n pathParams,\n queryParams: opts,\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Upload content and create a local representation\n *\n * @param file file\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRawRelatedContent(file: any): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(file, 'file');\n\n const formParams = {\n file\n };\n\n return this.post({\n path: '/api/enterprise/content/raw',\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Create a local representation of content from a remote repository\n *\n * @param relatedContent relatedContent\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRelatedContent(relatedContent: RelatedContentRepresentation): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n return this.post({\n path: '/api/enterprise/content',\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Remove a local content representation\n *\n * @param contentId contentId\n * @return Promise<{}>\n */\n deleteContent(contentId: number): Promise<void> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.delete({\n path: '/api/enterprise/content/{contentId}',\n pathParams\n });\n }\n\n /**\n * Get a local content representation\n *\n * @param contentId contentId\n * @return Promise<RelatedContentRepresentation>\n */\n getContent(contentId: number): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}',\n pathParams,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Get content Raw URL for the given contentId\n *\n * @param contentId contentId\n */\n getRawContentUrl(contentId: number): string {\n return `${this.apiClient.basePath}/api/enterprise/content/${contentId}/raw`;\n }\n\n /**\n * Stream content rendition\n *\n * @param contentId contentId\n * @param renditionType renditionType\n * @return Promise<{}>\n */\n getRawContent(contentId: number, renditionType?: string): Promise<any> {\n throwIfNotDefined(contentId, 'contentId');\n\n if (renditionType) {\n const pathParams = {\n contentId,\n renditionType\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/rendition/{renditionType}',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n } else {\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/raw',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n }\n }\n\n /**\n * List content attached to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForProcessInstance(\n processInstanceId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n return this.get({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * List content attached to a task\n *\n * @param taskId taskId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForTask(\n taskId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n\n const pathParams = {\n taskId\n };\n\n return this.get({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * Lists processes and tasks on workflow started with provided document\n *\n * @param sourceId - id of the document that workflow or task has been started with\n * @param source - source of the document that workflow or task has been started with\n * @param size - size of the entries to get\n * @param page - page number\n * @return Promise<ResultListDataRepresentationRelatedProcessTask>\n */\n getProcessesAndTasksOnContent(\n sourceId: string,\n source: string,\n size?: number,\n page?: number\n ): Promise<ResultListDataRepresentationRelatedProcessTask> {\n throwIfNotDefined(sourceId, 'sourceId');\n throwIfNotDefined(source, 'source');\n\n return this.get({\n path: '/api/enterprise/document-runtime',\n queryParams: {\n sourceId,\n source,\n size,\n page\n }\n });\n }\n}\n"]}
1
+ {"version":3,"file":"content.api.js","sourceRoot":"","sources":["content.api.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG;;;AAEH,oCAIkB;AAClB,yCAAqC;AACrC,4CAAoD;AAKpD,MAAa,UAAW,SAAQ,kBAAO;IAcnC,qCAAqC,CACjC,iBAAyB,EACzB,cAAkD,EAClD,IAAqC;QAErC,IAAA,0BAAiB,EAAC,iBAAiB,EAAE,mBAAmB,CAAC,CAAC;QAC1D,IAAA,0BAAiB,EAAC,cAAc,EAAE,gBAAgB,CAAC,CAAC;QAEpD,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAElB,MAAM,UAAU,GAAG;YACf,iBAAiB;SACpB,CAAC;QAEF,IAAI,cAAc,YAAY,oCAA4B,EAAE,CAAC;YACzD,OAAO,IAAI,CAAC,IAAI,CAAC;gBACb,IAAI,EAAE,+DAA+D;gBACrE,UAAU;gBACV,WAAW,EAAE,IAAI;gBACjB,SAAS,EAAE,cAAc;gBACzB,UAAU,EAAE,oCAA4B;aAC3C,CAAC,CAAC;QACP,CAAC;aAAM,CAAC;YACJ,MAAM,UAAU,GAAG;gBACf,IAAI,EAAE,cAAc;aACvB,CAAC;YAEF,OAAO,IAAI,CAAC,IAAI,CAAC;gBACb,IAAI,EAAE,mEAAmE;gBACzE,UAAU;gBACV,UAAU;gBACV,WAAW,EAAE,IAAI;gBACjB,YAAY,EAAE,CAAC,qBAAqB,CAAC;gBACrC,UAAU,EAAE,oCAA4B;aAC3C,CAAC,CAAC;QACP,CAAC;IACL,CAAC;IAUD,0BAA0B,CACtB,MAAc,EACd,cAAkD,EAClD,IAAqC;QAErC,IAAA,0BAAiB,EAAC,M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AAO,IAAI,CAAC,IAAI,CAAC;YACb,IAAI,EAAE,kCAAkC;YACxC,SAAS,EAAE,EAAE,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,IAAI,EAAE;SAC/C,CAAC,CAAC;IACP,CAAC;;AAtUL,gCAuUC;AAnUmB,4CAAiC,GAAG,GAAG,CAAC","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nimport {\n RelatedContentRepresentation,\n ResultListDataRepresentationRelatedContentRepresentation,\n ResultListDataRepresentationRelatedProcessTask\n} from '../model';\nimport { BaseApi } from './base.api';\nimport { throwIfNotDefined } from '../../../assert';\n\n/**\n * Content service.\n */\nexport class ContentApi extends BaseApi {\n /**\n * Maximum number of source document ids accepted by the batch document-runtime endpoint in a single request.\n */\n static readonly DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT = 500;\n\n /**\n * Attach existing content to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnProcessInstance(\n processInstanceId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/process-instances/{processInstanceId}/raw-content',\n pathParams,\n formParams,\n queryParams: opts,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Attach existing content to a task\n *\n * @param taskId taskId\n * @param relatedContent relatedContent\n * @param opts Optional parameters\n * @return Promise<RelatedContentRepresentation>\n */\n createRelatedContentOnTask(\n taskId: string,\n relatedContent: RelatedContentRepresentation | any,\n opts?: { isRelatedContent?: boolean }\n ): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n const pathParams = {\n taskId\n };\n\n if (relatedContent instanceof RelatedContentRepresentation) {\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n } else {\n const formParams = {\n file: relatedContent\n };\n\n return this.post({\n path: '/api/enterprise/tasks/{taskId}/raw-content',\n pathParams,\n queryParams: opts,\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n }\n\n /**\n * Upload content and create a local representation\n *\n * @param file file\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRawRelatedContent(file: any): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(file, 'file');\n\n const formParams = {\n file\n };\n\n return this.post({\n path: '/api/enterprise/content/raw',\n formParams,\n contentTypes: ['multipart/form-data'],\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Create a local representation of content from a remote repository\n *\n * @param relatedContent relatedContent\n * @return Promise<RelatedContentRepresentation>\n */\n createTemporaryRelatedContent(relatedContent: RelatedContentRepresentation): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(relatedContent, 'relatedContent');\n\n return this.post({\n path: '/api/enterprise/content',\n bodyParam: relatedContent,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Remove a local content representation\n *\n * @param contentId contentId\n * @return Promise<{}>\n */\n deleteContent(contentId: number): Promise<void> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.delete({\n path: '/api/enterprise/content/{contentId}',\n pathParams\n });\n }\n\n /**\n * Get a local content representation\n *\n * @param contentId contentId\n * @return Promise<RelatedContentRepresentation>\n */\n getContent(contentId: number): Promise<RelatedContentRepresentation> {\n throwIfNotDefined(contentId, 'contentId');\n\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}',\n pathParams,\n returnType: RelatedContentRepresentation\n });\n }\n\n /**\n * Get content Raw URL for the given contentId\n *\n * @param contentId contentId\n */\n getRawContentUrl(contentId: number): string {\n return `${this.apiClient.basePath}/api/enterprise/content/${contentId}/raw`;\n }\n\n /**\n * Stream content rendition\n *\n * @param contentId contentId\n * @param renditionType renditionType\n * @return Promise<{}>\n */\n getRawContent(contentId: number, renditionType?: string): Promise<any> {\n throwIfNotDefined(contentId, 'contentId');\n\n if (renditionType) {\n const pathParams = {\n contentId,\n renditionType\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/rendition/{renditionType}',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n } else {\n const pathParams = {\n contentId\n };\n\n return this.get({\n path: '/api/enterprise/content/{contentId}/raw',\n pathParams,\n returnType: 'blob',\n responseType: 'blob'\n });\n }\n }\n\n /**\n * List content attached to a process instance\n *\n * @param processInstanceId processInstanceId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForProcessInstance(\n processInstanceId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(processInstanceId, 'processInstanceId');\n\n opts = opts || {};\n\n const pathParams = {\n processInstanceId\n };\n\n return this.get({\n path: '/api/enterprise/process-instances/{processInstanceId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * List content attached to a task\n *\n * @param taskId taskId\n * @param opts Optional parameters\n * @return Promise<ResultListDataRepresentationRelatedContentRepresentation>\n */\n getRelatedContentForTask(\n taskId: string,\n opts?: { isRelatedContent?: boolean }\n ): Promise<ResultListDataRepresentationRelatedContentRepresentation> {\n throwIfNotDefined(taskId, 'taskId');\n\n const pathParams = {\n taskId\n };\n\n return this.get({\n path: '/api/enterprise/tasks/{taskId}/content',\n pathParams,\n queryParams: opts,\n returnType: ResultListDataRepresentationRelatedContentRepresentation\n });\n }\n\n /**\n * Lists processes and tasks on workflow started with provided document\n *\n * @param sourceId - id of the document that workflow or task has been started with\n * @param source - source of the document that workflow or task has been started with\n * @param size - size of the entries to get\n * @param page - page number\n * @return Promise<ResultListDataRepresentationRelatedProcessTask>\n */\n getProcessesAndTasksOnContent(\n sourceId: string,\n source: string,\n size?: number,\n page?: number\n ): Promise<ResultListDataRepresentationRelatedProcessTask> {\n throwIfNotDefined(sourceId, 'sourceId');\n throwIfNotDefined(source, 'source');\n\n return this.get({\n path: '/api/enterprise/document-runtime',\n queryParams: {\n sourceId,\n source,\n size,\n page\n }\n });\n }\n\n /**\n * Batch variant of getProcessesAndTasksOnContent. Accepts multiple source document ids\n * in one request (up to 500) and returns the related processes and tasks for all of them.\n *\n * @param sourceIds - ids of the documents to query process participation for (up to 500)\n * @param source - source of the documents that workflows or tasks have been started with\n * @param size - size of the entries to get\n * @param page - page number\n * @return Promise<ResultListDataRepresentationRelatedProcessTask>\n * @throws {Error} if sourceIds exceeds DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT\n */\n getProcessesAndTasksOnContentBatch(\n sourceIds: string[],\n source: string,\n size?: number,\n page?: number\n ): Promise<ResultListDataRepresentationRelatedProcessTask> {\n throwIfNotDefined(sourceIds, 'sourceIds');\n throwIfNotDefined(source, 'source');\n\n if (sourceIds.length > ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT) {\n throw new Error(`sourceIds length exceeds the maximum batch size of ${ContentApi.DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT}`);\n }\n\n return this.post({\n path: '/api/enterprise/document-runtime',\n bodyParam: { sourceIds, source, size, page }\n });\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"relatedProcessTask.js","sourceRoot":"","sources":["relatedProcessTask.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport interface RelatedProcessTask {\n processId?: string;\n taskId?: string;\n}\n"]}
1
+ {"version":3,"file":"relatedProcessTask.js","sourceRoot":"","sources":["relatedProcessTask.ts"],"names":[],"mappings":";AAAA;;;;;;;;;;;;;;;GAeG","sourcesContent":["/*!\n * @license\n * Copyright © 2005-2026 Hyland Software, Inc. and its affiliates. All rights reserved.\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\n\nexport interface RelatedProcessTask {\n processId?: string;\n taskId?: string;\n sourceId?: string;\n}\n"]}
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@alfresco/js-api",
3
- "version": "10.2.0-31151847596",
3
+ "version": "10.2.0-31162511335",
4
4
  "license": "Apache-2.0",
5
5
  "description": "JavaScript client library for the Alfresco REST API",
6
6
  "author": "Hyland Software, Inc. and its affiliates",
@@ -20,6 +20,10 @@ import { BaseApi } from './base.api';
20
20
  * Content service.
21
21
  */
22
22
  export declare class ContentApi extends BaseApi {
23
+ /**
24
+ * Maximum number of source document ids accepted by the batch document-runtime endpoint in a single request.
25
+ */
26
+ static readonly DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT = 500;
23
27
  /**
24
28
  * Attach existing content to a process instance
25
29
  *
@@ -114,4 +118,16 @@ export declare class ContentApi extends BaseApi {
114
118
  * @return Promise<ResultListDataRepresentationRelatedProcessTask>
115
119
  */
116
120
  getProcessesAndTasksOnContent(sourceId: string, source: string, size?: number, page?: number): Promise<ResultListDataRepresentationRelatedProcessTask>;
121
+ /**
122
+ * Batch variant of getProcessesAndTasksOnContent. Accepts multiple source document ids
123
+ * in one request (up to 500) and returns the related processes and tasks for all of them.
124
+ *
125
+ * @param sourceIds - ids of the documents to query process participation for (up to 500)
126
+ * @param source - source of the documents that workflows or tasks have been started with
127
+ * @param size - size of the entries to get
128
+ * @param page - page number
129
+ * @return Promise<ResultListDataRepresentationRelatedProcessTask>
130
+ * @throws {Error} if sourceIds exceeds DOCUMENT_RUNTIME_BATCH_SIZE_LIMIT
131
+ */
132
+ getProcessesAndTasksOnContentBatch(sourceIds: string[], source: string, size?: number, page?: number): Promise<ResultListDataRepresentationRelatedProcessTask>;
117
133
  }
@@ -17,4 +17,5 @@
17
17
  export interface RelatedProcessTask {
18
18
  processId?: string;
19
19
  taskId?: string;
20
+ sourceId?: string;
20
21
  }