diff --git a/browser.ts b/browser.ts deleted file mode 100644 index 557a822..0000000 --- a/browser.ts +++ /dev/null @@ -1,5 +0,0 @@ -export * from "./src/task/index"; -export * from "./src/common"; -export * from "./src/core"; -export * from "./src/orkes/browser"; - diff --git a/package.json b/package.json index b79a318..1a64e4a 100644 --- a/package.json +++ b/package.json @@ -7,11 +7,6 @@ "require": "./dist/index.js", "import": "./dist/index.mjs", "types": "./dist/index.d.ts" - }, - "./browser": { - "require": "./dist/browser.js", - "import": "./dist/browser.mjs", - "types": "./dist/browser.d.ts" } }, "private": false, @@ -30,7 +25,7 @@ "main": "dist/index.js", "scripts": { "lint": "npx eslint . --ext .js,.ts", - "build": "tsup", + "build": "tsup index.ts", "prepublishOnly": "npm run build", "lint-fix": "npx eslint . --fix --ext .js,.ts", "test": "jest --force-exit --detectOpenHandles", @@ -66,7 +61,6 @@ "dotenv": "^16.0.1", "eslint": "^6.1.0", "jest": "^29.4.3", - "@types/node-fetch": "^2.6.4", "ts-jest": "^29.0.5", "ts-node": "^10.7.0", "tsup": "^7.1.0", @@ -82,21 +76,13 @@ "esm", "cjs" ], - "entry": [ - "index.ts", - "browser.ts" - ], "dts": true, "clean": true, - "splitting": false, - "types": [ - "index.ts" - ] + "splitting": false }, "engines": { "node": ">=18" }, "dependencies": { - "node-fetch": "^2.6.12" } } diff --git a/src/common/index.ts b/src/common/index.ts index a904cf2..3a1ae5f 100644 --- a/src/common/index.ts +++ b/src/common/index.ts @@ -51,22 +51,16 @@ export { TokenResourceService, WorkflowBulkResourceService, WorkflowResourceService, - AssignmentPolicy, - Fixed, - BackToAssigment, - ClearAssigment, - Escalate, - FFAAssignment, HTScrollableSearchResultHumanTaskEntry, - HumanTaskActionLogEntry, - HumanTaskEntry, - HumanTaskLoad, - HumanTaskStateLogEntry, - HumanTaskTemplate, - HumanTaskTemplateEntry, - LeastBusyGroupMemberAssignment, - Never, - SearchResultHumanTaskEntry, Terminate, TimeoutPolicy, + HumanTaskUser, + HumanTaskDefinition, + HumanTaskAssignment, + HumanTaskTrigger, + UserFormTemplate, + HumanTaskTemplate, + HumanTaskSearchResult, + HumanTaskSearch, + HumanTaskEntry } from "./open-api"; diff --git a/src/common/open-api/index.ts b/src/common/open-api/index.ts index b983361..dff12ec 100644 --- a/src/common/open-api/index.ts +++ b/src/common/open-api/index.ts @@ -47,24 +47,18 @@ export type { WorkflowSummary } from "./models/WorkflowSummary"; export type { WorkflowTask } from "./models/WorkflowTask"; // HUMAN -export type { AssignmentPolicy } from "./models/AssignmentPolicy"; -export type { Fixed } from "./models/Fixed"; -export type { BackToAssigment } from "./models/BackToAssigment"; -export type { ClearAssigment } from "./models/ClearAssigment"; -export type { Escalate } from "./models/Escalate"; -export type { FFAAssignment } from "./models/FFAAssignment"; export type { HTScrollableSearchResultHumanTaskEntry } from "./models/HTScrollableSearchResultHumanTaskEntry"; -export type { HumanTaskActionLogEntry } from "./models/HumanTaskActionLogEntry"; -export type { HumanTaskEntry } from "./models/HumanTaskEntry"; -export type { HumanTaskLoad } from "./models/HumanTaskLoad"; -export type { HumanTaskStateLogEntry } from "./models/HumanTaskStateLogEntry"; +export type { HumanTaskUser } from "./models/HumanTaskUser"; +export type { HumanTaskDefinition } from "./models/HumanTaskDefinition"; +export type { HumanTaskAssignment } from "./models/HumanTaskAssignment"; +export type { HumanTaskTrigger } from "./models/HumanTaskTrigger"; +export type { UserFormTemplate } from "./models/UserFormTemplate"; export type { HumanTaskTemplate } from "./models/HumanTaskTemplate"; -export type { HumanTaskTemplateEntry } from "./models/HumanTaskTemplateEntry"; -export type { LeastBusyGroupMemberAssignment } from "./models/LeastBusyGroupMemberAssignment"; -export type { Never } from "./models/Never"; -export type { SearchResultHumanTaskEntry } from "./models/SearchResultHumanTaskEntry"; +export type { HumanTaskSearchResult } from "./models/HumanTaskSearchResult"; +export type { HumanTaskSearch } from "./models/HumanTaskSearch"; export type { Terminate } from "./models/Terminate"; export type { TimeoutPolicy } from "./models/TimeoutPolicy"; +export type { HumanTaskEntry } from "./models/HumanTaskEntry"; export { EventResourceService } from "./services/EventResourceService"; export { HealthCheckResourceService } from "./services/HealthCheckResourceService"; @@ -76,4 +70,3 @@ export { WorkflowBulkResourceService } from "./services/WorkflowBulkResourceServ export { WorkflowResourceService } from "./services/WorkflowResourceService"; export { HumanTaskResourceService } from "./services/HumanTaskResourceService"; export { HumanTaskService } from "./services/HumanTaskService"; - diff --git a/src/common/open-api/models/BackToAssigment.ts b/src/common/open-api/models/BackToAssigment.ts deleted file mode 100644 index 7cbbb69..0000000 --- a/src/common/open-api/models/BackToAssigment.ts +++ /dev/null @@ -1,10 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { TimeoutPolicy } from './TimeoutPolicy'; - -export type BackToAssigment = (TimeoutPolicy & { - timeoutSeconds?: number; -}); - diff --git a/src/common/open-api/models/ClearAssigment.ts b/src/common/open-api/models/ClearAssigment.ts deleted file mode 100644 index 31291d6..0000000 --- a/src/common/open-api/models/ClearAssigment.ts +++ /dev/null @@ -1,10 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { TimeoutPolicy } from './TimeoutPolicy'; - -export type ClearAssigment = (TimeoutPolicy & { - timeoutSeconds?: number; -}); - diff --git a/src/common/open-api/models/Escalate.ts b/src/common/open-api/models/Escalate.ts deleted file mode 100644 index f944509..0000000 --- a/src/common/open-api/models/Escalate.ts +++ /dev/null @@ -1,13 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { TimeoutPolicy } from './TimeoutPolicy'; - -export type Escalate = (TimeoutPolicy & { - subjects?: Array; - timeoutSeconds?: number; -} & { - subjects: Array; -}); - diff --git a/src/common/open-api/models/FFAAssignment.ts b/src/common/open-api/models/FFAAssignment.ts deleted file mode 100644 index dfc844c..0000000 --- a/src/common/open-api/models/FFAAssignment.ts +++ /dev/null @@ -1,8 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { AssignmentPolicy } from './AssignmentPolicy'; - -export type FFAAssignment = AssignmentPolicy; - diff --git a/src/common/open-api/models/Fixed.ts b/src/common/open-api/models/Fixed.ts deleted file mode 100644 index 58191b3..0000000 --- a/src/common/open-api/models/Fixed.ts +++ /dev/null @@ -1,11 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { AssignmentPolicy } from './AssignmentPolicy'; - -export type Fixed = (AssignmentPolicy & { - assignee?: string; - assigneeType?: 'EXTERNAL_USER' | 'EXTERNAL_GROUP' | 'CONDUCTOR_USER' | 'CONDUCTOR_GROUP'; -}); - diff --git a/src/common/open-api/models/HumanTaskActionLogEntry.ts b/src/common/open-api/models/HumanTaskActionLogEntry.ts deleted file mode 100644 index af29ff6..0000000 --- a/src/common/open-api/models/HumanTaskActionLogEntry.ts +++ /dev/null @@ -1,15 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -export type HumanTaskActionLogEntry = { - action?: string; - actionTime?: number; - cause?: string; - id?: string; - taskId?: string; - taskRefName?: string; - workflowId?: string; - workflowName?: string; -}; - diff --git a/src/common/open-api/models/HumanTaskAssignment.ts b/src/common/open-api/models/HumanTaskAssignment.ts new file mode 100644 index 0000000..3105227 --- /dev/null +++ b/src/common/open-api/models/HumanTaskAssignment.ts @@ -0,0 +1,11 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ + +import type { HumanTaskUser } from './HumanTaskUser'; + +export type HumanTaskAssignment = { + assignee?: HumanTaskUser; + slaMinutes?: number; +}; + diff --git a/src/common/open-api/models/HumanTaskDefinition.ts b/src/common/open-api/models/HumanTaskDefinition.ts new file mode 100644 index 0000000..3a3316e --- /dev/null +++ b/src/common/open-api/models/HumanTaskDefinition.ts @@ -0,0 +1,15 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ + +import type { HumanTaskAssignment } from './HumanTaskAssignment'; +import type { HumanTaskTrigger } from './HumanTaskTrigger'; +import type { UserFormTemplate } from './UserFormTemplate'; + +export type HumanTaskDefinition = { + assignmentCompletionStrategy?: 'LEAVE_OPEN' | 'TERMINATE'; + assignments?: Array; + taskTriggers?: Array; + userFormTemplate?: UserFormTemplate; +}; + diff --git a/src/common/open-api/models/HumanTaskEntry.ts b/src/common/open-api/models/HumanTaskEntry.ts index 7e04170..34bace4 100644 --- a/src/common/open-api/models/HumanTaskEntry.ts +++ b/src/common/open-api/models/HumanTaskEntry.ts @@ -2,32 +2,23 @@ /* tslint:disable */ /* eslint-disable */ -import type { BackToAssigment } from './BackToAssigment'; -import type { ClearAssigment } from './ClearAssigment'; -import type { Escalate } from './Escalate'; -import type { FFAAssignment } from './FFAAssignment'; -import type { Fixed } from './Fixed'; -import type { LeastBusyGroupMemberAssignment } from './LeastBusyGroupMemberAssignment'; -import type { Never } from './Never'; -import type { Terminate } from './Terminate'; +import type { HumanTaskDefinition } from './HumanTaskDefinition'; +import type { HumanTaskUser } from './HumanTaskUser'; export type HumanTaskEntry = { - assignee?: string; - assigneeType?: 'EXTERNAL_USER' | 'EXTERNAL_GROUP' | 'CONDUCTOR_USER' | 'CONDUCTOR_GROUP'; - assignmentPolicy?: (FFAAssignment | Fixed | LeastBusyGroupMemberAssignment); - claimedBy?: string; + assignee?: HumanTaskUser; + claimant?: HumanTaskUser; createdBy?: string; createdOn?: number; - escalatedAt?: number; - output?: Record>; - owners?: Array; - predefinedInput?: Record>; - state?: 'PENDING' | 'ASSIGNED' | 'IN_PROGRESS' | 'COMPLETED' | 'TIMED_OUT'; + definitionName?: string; + humanTaskDef?: HumanTaskDefinition; + input?: Record; + output?: Record; + state?: 'PENDING' | 'ASSIGNED' | 'IN_PROGRESS' | 'COMPLETED' | 'TIMED_OUT' | 'DELETED'; taskId?: string; - taskName?: string; taskRefName?: string; - templateId?: string; - timeoutPolicy?: (BackToAssigment | ClearAssigment | Escalate | Never | Terminate); + updatedBy?: string; + updatedOn?: number; workflowId?: string; workflowName?: string; }; diff --git a/src/common/open-api/models/HumanTaskLoad.ts b/src/common/open-api/models/HumanTaskLoad.ts deleted file mode 100644 index c03da84..0000000 --- a/src/common/open-api/models/HumanTaskLoad.ts +++ /dev/null @@ -1,11 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -export type HumanTaskLoad = { - assignedUser?: string; - count?: number; - taskRefName?: string; - workflowName?: string; -}; - diff --git a/src/common/open-api/models/HumanTaskSearch.ts b/src/common/open-api/models/HumanTaskSearch.ts new file mode 100644 index 0000000..80405a0 --- /dev/null +++ b/src/common/open-api/models/HumanTaskSearch.ts @@ -0,0 +1,20 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ + +import type { HumanTaskUser } from './HumanTaskUser'; + +export type HumanTaskSearch = { + assignees?: Array; + claimants?: Array; + definitionNames?: Array; + taskOutputQuery?: string; + taskInputQuery?: string; + searchType?: 'ADMIN' | 'INBOX'; + size?: number; + start?: number; + states?: Array<'PENDING' | 'ASSIGNED' | 'IN_PROGRESS' | 'COMPLETED' | 'TIMED_OUT' | 'DELETED'>; + taskRefNames?: Array; + workflowNames?: Array; +}; + diff --git a/src/common/open-api/models/SearchResultHumanTaskEntry.ts b/src/common/open-api/models/HumanTaskSearchResult.ts similarity index 81% rename from src/common/open-api/models/SearchResultHumanTaskEntry.ts rename to src/common/open-api/models/HumanTaskSearchResult.ts index 731533f..a2ebba3 100644 --- a/src/common/open-api/models/SearchResultHumanTaskEntry.ts +++ b/src/common/open-api/models/HumanTaskSearchResult.ts @@ -4,7 +4,7 @@ import type { HumanTaskEntry } from './HumanTaskEntry'; -export type SearchResultHumanTaskEntry = { +export type HumanTaskSearchResult = { results?: Array; totalHits?: number; }; diff --git a/src/common/open-api/models/HumanTaskStateLogEntry.ts b/src/common/open-api/models/HumanTaskStateLogEntry.ts deleted file mode 100644 index 382b598..0000000 --- a/src/common/open-api/models/HumanTaskStateLogEntry.ts +++ /dev/null @@ -1,18 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -export type HumanTaskStateLogEntry = { - assignee?: string; - assigneeType?: 'EXTERNAL_USER' | 'EXTERNAL_GROUP' | 'CONDUCTOR_USER' | 'CONDUCTOR_GROUP'; - claimedBy?: string; - id?: string; - state?: 'PENDING' | 'ASSIGNED' | 'IN_PROGRESS' | 'COMPLETED' | 'TIMED_OUT'; - stateEnd?: number; - stateStart?: number; - taskId?: string; - taskRefName?: string; - workflowId?: string; - workflowName?: string; -}; - diff --git a/src/common/open-api/models/HumanTaskTemplate.ts b/src/common/open-api/models/HumanTaskTemplate.ts index 3d772ed..07788d4 100644 --- a/src/common/open-api/models/HumanTaskTemplate.ts +++ b/src/common/open-api/models/HumanTaskTemplate.ts @@ -3,9 +3,13 @@ /* eslint-disable */ export type HumanTaskTemplate = { - jsonSchema: Record>; + createdBy?: string; + createdOn?: number; + jsonSchema: Record; name: string; - templateUI: Record>; - version?: number; + templateUI: Record; + updatedBy?: string; + updatedOn?: number; + version: number; }; diff --git a/src/common/open-api/models/HumanTaskTemplateEntry.ts b/src/common/open-api/models/HumanTaskTemplateEntry.ts deleted file mode 100644 index 20f49fb..0000000 --- a/src/common/open-api/models/HumanTaskTemplateEntry.ts +++ /dev/null @@ -1,16 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -export type HumanTaskTemplateEntry = { - createdBy?: string; - createdOn?: number; - id?: string; - jsonSchema?: Record>; - name?: string; - templateUI?: Record>; - updatedBy?: string; - updatedOn?: number; - version?: number; -}; - diff --git a/src/common/open-api/models/HumanTaskTrigger.ts b/src/common/open-api/models/HumanTaskTrigger.ts new file mode 100644 index 0000000..8650926 --- /dev/null +++ b/src/common/open-api/models/HumanTaskTrigger.ts @@ -0,0 +1,11 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ + +import type { StartWorkflowRequest } from './StartWorkflowRequest'; + +export type HumanTaskTrigger = { + startWorkflowRequest?: StartWorkflowRequest; + triggerType?: 'ASSIGNEE_CHANGED' | 'PENDING' | 'IN_PROGRESS' | 'ASSIGNED' | 'COMPLETED' | 'TIMED_OUT'; +}; + diff --git a/src/common/open-api/models/HumanTaskUser.ts b/src/common/open-api/models/HumanTaskUser.ts new file mode 100644 index 0000000..8d71673 --- /dev/null +++ b/src/common/open-api/models/HumanTaskUser.ts @@ -0,0 +1,9 @@ +/* istanbul ignore file */ +/* tslint:disable */ +/* eslint-disable */ + +export type HumanTaskUser = { + user?: string; + userType?: 'EXTERNAL_USER' | 'EXTERNAL_GROUP' | 'CONDUCTOR_USER' | 'CONDUCTOR_GROUP'; +}; + diff --git a/src/common/open-api/models/LeastBusyGroupMemberAssignment.ts b/src/common/open-api/models/LeastBusyGroupMemberAssignment.ts deleted file mode 100644 index 471b454..0000000 --- a/src/common/open-api/models/LeastBusyGroupMemberAssignment.ts +++ /dev/null @@ -1,10 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { AssignmentPolicy } from './AssignmentPolicy'; - -export type LeastBusyGroupMemberAssignment = (AssignmentPolicy & { - groupId?: string; -}); - diff --git a/src/common/open-api/models/Never.ts b/src/common/open-api/models/Never.ts deleted file mode 100644 index 87beef0..0000000 --- a/src/common/open-api/models/Never.ts +++ /dev/null @@ -1,8 +0,0 @@ -/* istanbul ignore file */ -/* tslint:disable */ -/* eslint-disable */ - -import type { TimeoutPolicy } from './TimeoutPolicy'; - -export type Never = TimeoutPolicy; - diff --git a/src/common/open-api/models/AssignmentPolicy.ts b/src/common/open-api/models/UserFormTemplate.ts similarity index 51% rename from src/common/open-api/models/AssignmentPolicy.ts rename to src/common/open-api/models/UserFormTemplate.ts index 4de9818..a8bb419 100644 --- a/src/common/open-api/models/AssignmentPolicy.ts +++ b/src/common/open-api/models/UserFormTemplate.ts @@ -2,7 +2,8 @@ /* tslint:disable */ /* eslint-disable */ -export type AssignmentPolicy = { - type: string; +export type UserFormTemplate = { + name?: string; + version?: number; }; diff --git a/src/common/open-api/services/HumanTaskService.ts b/src/common/open-api/services/HumanTaskService.ts index 2f370f8..c794bd0 100644 --- a/src/common/open-api/services/HumanTaskService.ts +++ b/src/common/open-api/services/HumanTaskService.ts @@ -1,17 +1,11 @@ /* istanbul ignore file */ /* tslint:disable */ /* eslint-disable */ -import type { FFAAssignment } from '../models/FFAAssignment'; -import type { Fixed } from '../models/Fixed'; -import type { HTScrollableSearchResultHumanTaskEntry } from '../models/HTScrollableSearchResultHumanTaskEntry'; -import type { HumanTaskActionLogEntry } from '../models/HumanTaskActionLogEntry'; +import type { HumanTaskAssignment } from '../models/HumanTaskAssignment'; import type { HumanTaskEntry } from '../models/HumanTaskEntry'; -import type { HumanTaskLoad } from '../models/HumanTaskLoad'; -import type { HumanTaskStateLogEntry } from '../models/HumanTaskStateLogEntry'; +import type { HumanTaskSearch } from '../models/HumanTaskSearch'; +import type { HumanTaskSearchResult } from '../models/HumanTaskSearchResult'; import type { HumanTaskTemplate } from '../models/HumanTaskTemplate'; -import type { HumanTaskTemplateEntry } from '../models/HumanTaskTemplateEntry'; -import type { LeastBusyGroupMemberAssignment } from '../models/LeastBusyGroupMemberAssignment'; -import type { SearchResultHumanTaskEntry } from '../models/SearchResultHumanTaskEntry'; import type { CancelablePromise } from '../core/CancelablePromise'; import type { BaseHttpRequest } from '../core/BaseHttpRequest'; @@ -21,104 +15,85 @@ export class HumanTaskService { constructor(public readonly httpRequest: BaseHttpRequest) {} /** - * List tasks by filters - task name, state, assignee, assignee type, claimed - * @param state - * @param assignee - * @param assigneeType - * @param claimedBy - * @param taskName - * @param freeText - * @param includeInputOutput - * @returns SearchResultHumanTaskEntry OK + * If the workflow is disconnected from tasks, this API can be used to clean up (in bulk) + * @param requestBody + * @returns any OK * @throws ApiError */ - public getTasksByFilter( - state: 'PENDING' | 'ASSIGNED' | 'IN_PROGRESS' | 'COMPLETED' | 'TIMED_OUT', - assignee?: string, - assigneeType?: 'EXTERNAL_USER' | 'EXTERNAL_GROUP' | 'CONDUCTOR_USER' | 'CONDUCTOR_GROUP', - claimedBy?: string, - taskName?: string, - freeText?: string, - includeInputOutput: boolean = false, - ): CancelablePromise { + public deleteTaskFromHumanTaskRecords( + requestBody: Array, + ): CancelablePromise { return this.httpRequest.request({ - method: 'GET', - url: '/human/tasks', - query: { - 'state': state, - 'assignee': assignee, - 'assigneeType': assigneeType, - 'claimedBy': claimedBy, - 'taskName': taskName, - 'freeText': freeText, - 'includeInputOutput': includeInputOutput, - }, + method: 'DELETE', + url: '/human/tasks/delete', + body: requestBody, + mediaType: 'application/json', }); } /** - * Get task load grouped by workflow name and task ref name per user - * @returns HumanTaskLoad OK + * If the workflow is disconnected from tasks, this API can be used to clean up + * @param taskId + * @returns any OK * @throws ApiError */ - public getTaskLoad(): CancelablePromise> { + public deleteTaskFromHumanTaskRecords1( + taskId: string, + ): CancelablePromise { return this.httpRequest.request({ - method: 'GET', - url: '/human/tasks/load', + method: 'DELETE', + url: '/human/tasks/delete/{taskId}', + path: { + 'taskId': taskId, + }, }); } /** * Search human tasks - * @param queryId - * @param start - * @param size - * @param freeText - * @param query - * @param jsonQuery - * @param includeInputOutput - * @returns HTScrollableSearchResultHumanTaskEntry OK + * @param requestBody + * @returns HumanTaskSearchResult OK * @throws ApiError */ - public search1( - queryId?: string, - start?: number, - size: number = 100, - freeText: string = '*', - query?: string, - jsonQuery?: string, - includeInputOutput: boolean = false, - ): CancelablePromise { + public search( + requestBody: HumanTaskSearch, + ): CancelablePromise { return this.httpRequest.request({ - method: 'GET', + method: 'POST', url: '/human/tasks/search', - query: { - 'queryId': queryId, - 'start': start, - 'size': size, - 'freeText': freeText, - 'query': query, - 'jsonQuery': jsonQuery, - 'includeInputOutput': includeInputOutput, - }, + body: requestBody, + mediaType: 'application/json', }); } /** - * If the workflow is disconnected from tasks, this API can be used to clean up - * @param taskId + * Update task output, optionally complete + * @param workflowId + * @param taskRefName + * @param requestBody + * @param complete + * @param iteration Populate this value if your task is in a loop and you want to update a specific iteration. If its not in a loop OR if you want to just update the latest iteration, leave this as empty * @returns any OK * @throws ApiError */ - public updateTaskOutput1( - taskId: string, + public updateTaskOutputByRef( + workflowId: string, + taskRefName: string, + requestBody: Record, + complete: boolean = false, + iteration?: Array, ): CancelablePromise { return this.httpRequest.request({ - method: 'DELETE', - url: '/human/tasks/{taskId}', - path: { - 'taskId': taskId, + method: 'POST', + url: '/human/tasks/update/taskRef', + query: { + 'workflowId': workflowId, + 'taskRefName': taskRefName, + 'complete': complete, + 'iteration': iteration, }, + body: requestBody, + mediaType: 'application/json', }); } @@ -140,39 +115,26 @@ export class HumanTaskService { }); } - /** - * Get human task action log entries by task id - * @param taskId - * @returns HumanTaskActionLogEntry OK - * @throws ApiError - */ - public getActionLogs( - taskId: string, - ): CancelablePromise> { - return this.httpRequest.request({ - method: 'GET', - url: '/human/tasks/{taskId}/actionLogs', - path: { - 'taskId': taskId, - }, - }); - } - /** * Claim a task by authenticated Conductor user * @param taskId + * @param overrideAssignment * @returns any OK * @throws ApiError */ public claimTask( taskId: string, - ): CancelablePromise { + overrideAssignment: boolean = false, + ): CancelablePromise { return this.httpRequest.request({ method: 'POST', url: '/human/tasks/{taskId}/claim', path: { 'taskId': taskId, }, + query: { + 'overrideAssignment': overrideAssignment, + }, }); } @@ -180,13 +142,15 @@ export class HumanTaskService { * Claim a task to an external user * @param taskId * @param userId + * @param overrideAssignment * @returns any OK * @throws ApiError */ public assignAndClaim( taskId: string, userId: string, - ): CancelablePromise { + overrideAssignment: boolean = false, + ): CancelablePromise { return this.httpRequest.request({ method: 'POST', url: '/human/tasks/{taskId}/externalUser/{userId}', @@ -194,6 +158,9 @@ export class HumanTaskService { 'taskId': taskId, 'userId': userId, }, + query: { + 'overrideAssignment': overrideAssignment, + }, }); } @@ -206,7 +173,7 @@ export class HumanTaskService { */ public reassignTask( taskId: string, - requestBody: (FFAAssignment | Fixed | LeastBusyGroupMemberAssignment), + requestBody: Array, ): CancelablePromise { return this.httpRequest.request({ method: 'POST', @@ -238,20 +205,25 @@ export class HumanTaskService { } /** - * Get human task state log entries by task id + * If a task is assigned to a user, this API can be used to skip that assignment and move to the next assignee * @param taskId - * @returns HumanTaskStateLogEntry OK + * @param reason + * @returns any OK * @throws ApiError */ - public getStateLogs( + public skipTask( taskId: string, - ): CancelablePromise> { + reason?: string, + ): CancelablePromise { return this.httpRequest.request({ - method: 'GET', - url: '/human/tasks/{taskId}/stateLogs', + method: 'POST', + url: '/human/tasks/{taskId}/skip', path: { 'taskId': taskId, }, + query: { + 'reason': reason, + }, }); } @@ -265,7 +237,7 @@ export class HumanTaskService { */ public updateTaskOutput( taskId: string, - requestBody: Record>, + requestBody: Record, complete: boolean = false, ): CancelablePromise { return this.httpRequest.request({ @@ -283,58 +255,62 @@ export class HumanTaskService { } /** - * Delete human task templates by name + * List all user form templates or get templates by name, or a template by name and version * @param name - * @returns any OK + * @param version + * @returns HumanTaskTemplate OK * @throws ApiError */ - public deleteTemplatesByName( - name: string, - ): CancelablePromise { + public getAllTemplates( + name?: string, + version?: number, + ): CancelablePromise> { return this.httpRequest.request({ - method: 'DELETE', + method: 'GET', url: '/human/template', query: { 'name': name, + 'version': version, }, }); } /** - * List all human task templates or get templates by name, or a template by name and version - * @param name - * @param version - * @returns HumanTaskTemplateEntry OK + * Save user form template + * @param requestBody + * @param newVersion + * @returns HumanTaskTemplate OK * @throws ApiError */ - public getAllTemplates( - name?: string, - version?: number, - ): CancelablePromise> { + public saveTemplate( + requestBody: HumanTaskTemplate, + newVersion: boolean = false, + ): CancelablePromise { return this.httpRequest.request({ - method: 'GET', + method: 'POST', url: '/human/template', query: { - 'name': name, - 'version': version, + 'newVersion': newVersion, }, + body: requestBody, + mediaType: 'application/json', }); } /** - * Save human task template + * Save user form template * @param requestBody * @param newVersion - * @returns string OK + * @returns HumanTaskTemplate OK * @throws ApiError */ - public saveTemplate( - requestBody: HumanTaskTemplate, + public saveTemplates( + requestBody: Array, newVersion: boolean = false, - ): CancelablePromise { + ): CancelablePromise> { return this.httpRequest.request({ method: 'POST', - url: '/human/template', + url: '/human/template/bulk', query: { 'newVersion': newVersion, }, @@ -344,37 +320,61 @@ export class HumanTaskService { } /** - * Delete human task template - * @param id + * Delete all versions of user form template by name + * @param name * @returns any OK * @throws ApiError */ - public deleteTemplateById( - id: string, + public deleteTemplateByName( + name: string, ): CancelablePromise { return this.httpRequest.request({ method: 'DELETE', - url: '/human/template/{id}', + url: '/human/template/{name}', path: { - 'id': id, + 'name': name, }, }); } /** - * Get human task template by id - * @param id - * @returns HumanTaskTemplateEntry OK + * Delete a version of form template by name + * @param name + * @param version + * @returns any OK * @throws ApiError */ - public getTemplateById( - id: string, - ): CancelablePromise { + public deleteTemplatesByNameAndVersion( + name: string, + version: number, + ): CancelablePromise { + return this.httpRequest.request({ + method: 'DELETE', + url: '/human/template/{name}/{version}', + path: { + 'name': name, + 'version': version, + }, + }); + } + + /** + * Get user form template by name and version + * @param name + * @param version + * @returns HumanTaskTemplate OK + * @throws ApiError + */ + public getTemplateByNameAndVersion( + name: string, + version: number, + ): CancelablePromise { return this.httpRequest.request({ method: 'GET', - url: '/human/template/{id}', + url: '/human/template/{name}/{version}', path: { - 'id': id, + 'name': name, + 'version': version, }, }); } diff --git a/src/core/executor.ts b/src/core/executor.ts index 13879d4..8542c0e 100644 --- a/src/core/executor.ts +++ b/src/core/executor.ts @@ -10,10 +10,17 @@ import { ScrollableSearchResultWorkflowSummary, } from "../common/open-api"; import { TaskResultStatus } from "./types"; -import { errorMapper, tryCatchReThrow } from "./helpers"; +import { errorMapper, reverseFind, tryCatchReThrow } from "./helpers"; const RETRY_TIME_IN_MILLISECONDS = 10000; +export type TaskFinderPredicate = (task: Task) => boolean; + +export const completedTaskMatchingType = + (taskType: string): TaskFinderPredicate => + (task: Task) => + task.status === "COMPLETED" && task.taskType === taskType; + export class WorkflowExecutor { public readonly _client: ConductorClient; @@ -74,6 +81,35 @@ export class WorkflowExecutor { ): Promise[] { return tryCatchReThrow(() => workflowsRequest.map(this.startWorkflow)); } + + public async goBackToTask( + workflowInstanceId: string, + taskFinderPredicate: TaskFinderPredicate, + rerunWorkflowRequestOverrides: Partial = {} + ): Promise { + const { tasks: executedTasks = [] } = await this.getExecution( + workflowInstanceId + ); + const maybePreviousTask = reverseFind( + executedTasks, + taskFinderPredicate + ); + + if (!maybePreviousTask) { + throw new Error("Task not found"); + } + + await this.reRun(workflowInstanceId, { + //taskInput: previousTask.inputData, + ...rerunWorkflowRequestOverrides, + reRunFromTaskId: maybePreviousTask.taskId, + }); + } + + public async goBackToFirstTaskMatchingType(workflowInstanceId: string, taskType: string): Promise { + return this.goBackToTask(workflowInstanceId, completedTaskMatchingType(taskType)); + } + /** * Takes an workflowInstanceId and an includeTasks and an optional retry parameter returns the whole execution status. * If includeTasks flag is provided. Details of tasks execution will be returned as well, @@ -131,6 +167,26 @@ export class WorkflowExecutor { ); } + /** + * Returns a summary of the current workflow status. + * + * @param workflowInstanceId current running workflow + * @param includeOutput flag to include output + * @param includeVariables flag to include variable + * @returns Promise + */ + public getExecution( + workflowInstanceId: string, + includeTasks: boolean = true + ): Promise { + return tryCatchReThrow(() => + this._client.workflowResource.getExecutionStatus( + workflowInstanceId, + includeTasks + ) + ); + } + /** * Pauses a running workflow * @param workflowInstanceId current workflow execution diff --git a/src/core/helpers.ts b/src/core/helpers.ts index 13f99eb..8950713 100644 --- a/src/core/helpers.ts +++ b/src/core/helpers.ts @@ -1,4 +1,4 @@ -import { ConductorError} from "./types"; +import { ConductorError } from "./types"; export const errorMapper = (error: any): ConductorError => new ConductorError(error?.body?.message, error); @@ -10,3 +10,15 @@ export const tryCatchReThrow = (fn: Function) => { throw errorMapper(error); } }; + +export function reverseFind( + array: T[], + predicate: (a: T, idx?: number, arr?: T[]) => boolean +): T | undefined { + for (let i = array.length - 1; i >= 0; i--) { + if (predicate(array[i], i, array)) { + return array[i]; + } + } + return undefined; +} diff --git a/src/core/human.ts b/src/core/human.ts index 14946fb..e50a503 100644 --- a/src/core/human.ts +++ b/src/core/human.ts @@ -1,17 +1,44 @@ import { ConductorClient, + HumanTaskSearch, HumanTaskEntry, - HumanTaskTemplateEntry, + HumanTaskTemplate, } from "../common"; import { errorMapper, tryCatchReThrow } from "./helpers"; +type UserType = + | "EXTERNAL_USER" + | "EXTERNAL_GROUP" + | "CONDUCTOR_USER" + | "CONDUCTOR_GROUP"; + +const EMPTY_SEARCH: HumanTaskSearch = { + size: 15, + states: [], + taskInputQuery: "", + taskOutputQuery: "", + definitionNames: [], + taskRefNames: [], + claimants: [], + assignees: [], + start: 0, +}; + +const DEFAULT_POLL_INTERVAL = { pollInterval: 100, maxPollTimes: 20 }; + +type PollIntervalOptions = { + pollInterval: number; + maxPollTimes: number; +}; export class HumanExecutor { public readonly _client: ConductorClient; constructor(client: ConductorClient) { this._client = client; } + /** + * @deprecated use search instead * Takes a set of filter parameters. return matches of human tasks for that set of parameters * @param state * @param assignee @@ -32,17 +59,46 @@ export class HumanExecutor { | "CONDUCTOR_GROUP", claimedBy?: string, taskName?: string, - freeText?: string, - includeInputOutput: boolean = false + taskInputQuery?: string, + taskOutputQuery?: string, + ): Promise { + const [claimedUserType, claimedUser] = claimedBy?.split(":") ?? []; + + if (claimedUserType && !claimedUser) { + throw new Error("claimedBy should be in the format of :"); + } + + const response = await this.search({ + states: [state], + assignees: assignee ? [{ userType: assigneeType!, user: assignee }] : [], + claimants: claimedBy + ? [{ userType: claimedUserType as UserType, user: claimedUser }] + : [], + taskRefNames: taskName ? [taskName] : [], + taskInputQuery, + taskOutputQuery + }); + + return response; + } + + /** + * Takes a set of filter parameters. return matches of human tasks for that set of parameters + * @param state + * @param assignee + * @param assigneeType + * @param claimedBy + * @param taskName + * @param freeText + * @param includeInputOutput + * @returns Promise + */ + public async search( + searchParams: Partial ): Promise { - const response = await this._client.humanTask.getTasksByFilter( - state, - assignee, - assigneeType, - claimedBy, - taskName, - freeText, - includeInputOutput + const search = { ...EMPTY_SEARCH, ...searchParams }; + const response = await tryCatchReThrow(() => + this._client.humanTask.search(search) ); if (response.results != undefined) { return response.results; @@ -50,6 +106,36 @@ export class HumanExecutor { return []; } + /** + * Takes a set of filter parameters. An polling interval options. will poll until the task returns a result + * @param state + * @param assignee + * @param assigneeType + * @param claimedBy + * @param taskName + * @param freeText + * @param includeInputOutput + * @returns Promise + */ + public async pollSearch( + searchParams: Partial, + { + pollInterval = 100, + maxPollTimes = 20, + }: PollIntervalOptions = DEFAULT_POLL_INTERVAL + ): Promise { + let pollCount = 0; + while (pollCount < maxPollTimes) { + const response = await this.search(searchParams); + if (response.length > 0) { + return response; + } + await new Promise((resolve) => setTimeout(resolve, pollInterval)); + pollCount++; + } + return []; + } + /** * Returns task for a given task id * @param taskId @@ -65,12 +151,13 @@ export class HumanExecutor { * @param assignee * @returns */ - public async claimTaskAsExternalUser(taskId: string, assignee: string) { - try { - await this._client.humanTask.assignAndClaim(taskId, assignee); - } catch (error: any) { - throw errorMapper(error); - } + public async claimTaskAsExternalUser( + taskId: string, + assignee: string + ): Promise { + return tryCatchReThrow(() => + this._client.humanTask.assignAndClaim(taskId, assignee) + ); } /** @@ -78,12 +165,10 @@ export class HumanExecutor { * @param taskId * @returns */ - public async claimTaskAsConductorUser(taskId: string) { - try { - await this._client.humanTask.claimTask(taskId); - } catch (error: any) { - throw errorMapper(error); - } + public async claimTaskAsConductorUser( + taskId: string + ): Promise { + return tryCatchReThrow(() => this._client.humanTask.claimTask(taskId)); } /** @@ -101,18 +186,31 @@ export class HumanExecutor { } /** - * Returns a HumanTaskTemplateEntry for a given templateId + * Returns a HumanTaskTemplateEntry for a given name and version * @param templateId * @returns */ - public async getTemplateById( - templateId: string - ): Promise { + public async getTemplateByNameVersion( + name: string, + version: number + ): Promise { return tryCatchReThrow(() => - this._client.humanTask.getTemplateById(templateId) + this._client.humanTask.getTemplateByNameAndVersion(name, version) ); } + /** + * @deprecated use getTemplate instead. name will be used as id here with version 1 + * Returns a HumanTaskTemplateEntry for a given templateId + * @param templateId + * @returns + */ + public async getTemplateById( + templateNameVersionOne: string + ): Promise { + return this.getTemplateByNameVersion(templateNameVersionOne, 1); + } + /** * Takes a taskId and a partial body. will update with given body * @param taskId diff --git a/src/orkes/BrowserOrkesConductorClient.ts b/src/orkes/BrowserOrkesConductorClient.ts deleted file mode 100644 index 2c1d737..0000000 --- a/src/orkes/BrowserOrkesConductorClient.ts +++ /dev/null @@ -1,19 +0,0 @@ -import type { ConductorHttpRequest } from "../common"; -import { baseOrkesConductorClient } from "./BaseOrkesConductorClient"; - -const defaultRequestHandler: ConductorHttpRequest = ( - request, - config, - options -) => request(config, options); -/** - * Takes a config with keyId and keySecret returns a promise with an instance of ConductorClient - * - * @param config ConductorClientConfig with keyId and keySecret - * @param requestHandler (optional) ConductorHttpRequest handler - * @returns - */ -export const orkesConductorClient = baseOrkesConductorClient( - fetch, - defaultRequestHandler -); diff --git a/src/orkes/OrkesConductorClient.ts b/src/orkes/OrkesConductorClient.ts index aa11495..2c1d737 100644 --- a/src/orkes/OrkesConductorClient.ts +++ b/src/orkes/OrkesConductorClient.ts @@ -1,44 +1,11 @@ -import { ConductorHttpRequest } from "../common"; -import { fetchCatchDns } from "./request/fetchCatchDns"; -import { request as baseRequest } from "./request/request"; +import type { ConductorHttpRequest } from "../common"; import { baseOrkesConductorClient } from "./BaseOrkesConductorClient"; -import { FetchFn } from "./types"; -import fetch, { Headers, RequestInit, Response } from "node-fetch"; -import http from "http"; -import https from "https"; - -const httpAgent = new http.Agent({ keepAlive: true }); -const httpsAgent = new https.Agent({ keepAlive: true }); - -const agent = (_parsedURL: URL) => - _parsedURL.protocol == "http:" ? httpAgent : httpsAgent; - -const nodeFetchWrapper: FetchFn = async ( - input, - options = {} -) => { - const res = await fetch(input.toString(), { - ...options, - agent, - } as RequestInit); - return res; -}; - -const fetchCache = fetchCatchDns<{ headers: Record }, Response>( - nodeFetchWrapper, - { - //@ts-ignore - headerFactory: (headers?: HeadersInit) => - new Headers((headers as Record) || {}), - } -); const defaultRequestHandler: ConductorHttpRequest = ( - __request, + request, config, options -) => baseRequest(config, options, fetchCache as unknown as FetchFn); - +) => request(config, options); /** * Takes a config with keyId and keySecret returns a promise with an instance of ConductorClient * @@ -47,6 +14,6 @@ const defaultRequestHandler: ConductorHttpRequest = ( * @returns */ export const orkesConductorClient = baseOrkesConductorClient( - fetchCache, + fetch, defaultRequestHandler ); diff --git a/src/orkes/browser.ts b/src/orkes/browser.ts deleted file mode 100644 index 6610a3f..0000000 --- a/src/orkes/browser.ts +++ /dev/null @@ -1,4 +0,0 @@ -import type { FetchFn, OrkesApiConfig } from "./types"; -export type { FetchFn, OrkesApiConfig }; -export * from "./BrowserOrkesConductorClient"; - diff --git a/src/orkes/index.ts b/src/orkes/index.ts index cebb114..3b0c357 100644 --- a/src/orkes/index.ts +++ b/src/orkes/index.ts @@ -1,7 +1,6 @@ export * from "./OrkesConductorClient"; export * from "./BaseOrkesConductorClient"; export * from "./request/request"; -export * from "./request/fetchCatchDns"; import type { FetchFn, OrkesApiConfig } from "./types"; export type { FetchFn, OrkesApiConfig }; diff --git a/tsconfig.json b/tsconfig.json index 40b9959..9df6ce1 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,5 +1,5 @@ { - "extends": "@tsconfig/node16/tsconfig.json", + "extends": "@tsconfig/node18/tsconfig.json", "compilerOptions": { "lib": ["es2018","dom"] } diff --git a/yarn.lock b/yarn.lock index 6f65f4f..711bd0a 100644 --- a/yarn.lock +++ b/yarn.lock @@ -1064,14 +1064,6 @@ resolved "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.11.tgz" integrity sha512-wOuvG1SN4Us4rez+tylwwwCV1psiNVOkJeM3AUWUNWg/jDQY2+HE/444y5gc+jBmRqASOm2Oeh5c1axHobwRKQ== -"@types/node-fetch@^2.6.4": - version "2.6.4" - resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.4.tgz#1bc3a26de814f6bf466b25aeb1473fa1afe6a660" - integrity sha512-1ZX9fcN4Rvkvgv4E6PAY5WXUFWFcRWxZa3EW83UjycOB9ljJCedb2CupIP4RZMEwF/M3eTcCihbBRgwtGbg5Rg== - dependencies: - "@types/node" "*" - form-data "^3.0.0" - "@types/node@*", "@types/node@^18.11.18": version "18.16.0" resolved "https://registry.npmjs.org/@types/node/-/node-18.16.0.tgz" @@ -1285,11 +1277,6 @@ astral-regex@^1.0.0: resolved "https://registry.npmjs.org/astral-regex/-/astral-regex-1.0.0.tgz" integrity sha512-+Ryf6g3BKoRc7jfp7ad8tM4TtMiaWvbF/1/sQcZPkkS7ag3D5nMBCe2UfOTONtAkaG0tO0ij3C5Lwmf1EiyjHg== -asynckit@^0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" - integrity sha512-Oei9OH4tRh0YqU3GxhX79dM/mwVgvbZJaSNaRk+bshkj0S5cfHcgYakreBjrHwatXKbz+IoIdYLxrKim2MjW0Q== - babel-jest@^29.5.0: version "29.5.0" resolved "https://registry.yarnpkg.com/babel-jest/-/babel-jest-29.5.0.tgz#3fe3ddb109198e78b1c88f9ebdecd5e4fc2f50a5" @@ -1551,13 +1538,6 @@ color-name@~1.1.4: resolved "https://registry.npmjs.org/color-name/-/color-name-1.1.4.tgz" integrity sha512-dOy+3AuW3a2wNbZHIuMZpTcgjGuLU/uBL/ubcZF9OXbDo8ff4O8yVp5Bf0efS8uEoYo5q4Fx7dY9OgQGXgAsQA== -combined-stream@^1.0.8: - version "1.0.8" - resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" - integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== - dependencies: - delayed-stream "~1.0.0" - commander@^4.0.0: version "4.1.1" resolved "https://registry.npmjs.org/commander/-/commander-4.1.1.tgz" @@ -1627,11 +1607,6 @@ deepmerge@^4.2.2: resolved "https://registry.npmjs.org/deepmerge/-/deepmerge-4.2.2.tgz" integrity sha512-FJ3UgI4gIl+PHZm53knsuSFpE+nESMr7M4v9QcgB7S63Kj/6WqMiFQJpBBYz1Pt+66bZpP3Q7Lye0Oo9MPKEdg== -delayed-stream@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/delayed-stream/-/delayed-stream-1.0.0.tgz#df3ae199acadfb7d440aaae0b29e2272b24ec619" - integrity sha512-ZySD7Nf91aLB0RxL4KGrKHBXl7Eds1DAmEdcoVawXnLD7SDhpNgtuII2aAkg7a7QS41jxPSZ17p4VdGnMHk3MQ== - detect-newline@^3.0.0: version "3.1.0" resolved "https://registry.npmjs.org/detect-newline/-/detect-newline-3.1.0.tgz" @@ -1982,15 +1957,6 @@ flatted@^2.0.0: resolved "https://registry.npmjs.org/flatted/-/flatted-2.0.2.tgz" integrity sha512-r5wGx7YeOwNWNlCA0wQ86zKyDLMQr+/RB8xy74M4hTphfmjlijTSSXGuH8rnvKZnfT9i+75zmd8jcKdMR4O6jA== -form-data@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-3.0.1.tgz#ebd53791b78356a99af9a300d4282c4d5eb9755f" - integrity sha512-RHkBKtLWUVwd7SqRIvCZMEvAMoGUp0XU+seQiZejj0COz3RI3hWP4sCv3gZWWLjJTd7rGwcsF5eKZGii0r/hbg== - dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.8" - mime-types "^2.1.12" - fs.realpath@^1.0.0: version "1.0.0" resolved "https://registry.npmjs.org/fs.realpath/-/fs.realpath-1.0.0.tgz" @@ -2826,18 +2792,6 @@ micromatch@^4.0.4: braces "^3.0.2" picomatch "^2.3.1" -mime-db@1.52.0: - version "1.52.0" - resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" - integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== - -mime-types@^2.1.12: - version "2.1.35" - resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" - integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== - dependencies: - mime-db "1.52.0" - mimic-fn@^2.1.0: version "2.1.0" resolved "https://registry.npmjs.org/mimic-fn/-/mimic-fn-2.1.0.tgz" @@ -2903,13 +2857,6 @@ nice-try@^1.0.4: resolved "https://registry.npmjs.org/nice-try/-/nice-try-1.0.5.tgz" integrity sha512-1nh45deeb5olNY7eX82BkPO7SSxR5SSYJiPTrTdFUVYwAl8CKMA5N9PjTYkHiRjisVcxcQ1HXdLhx2qxxJzLNQ== -node-fetch@^2.6.12: - version "2.6.12" - resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.6.12.tgz#02eb8e22074018e3d5a83016649d04df0e348fba" - integrity sha512-C/fGU2E8ToujUivIO0H+tpQ6HWo4eEmchoPIoXtxCrVghxdKq+QOHqEZW7tuP3KlV3bC8FRMO5nMCC7Zm1VP6g== - dependencies: - whatwg-url "^5.0.0" - node-int64@^0.4.0: version "0.4.0" resolved "https://registry.npmjs.org/node-int64/-/node-int64-0.4.0.tgz" @@ -3500,11 +3447,6 @@ tr46@^1.0.1: dependencies: punycode "^2.1.0" -tr46@~0.0.3: - version "0.0.3" - resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" - integrity sha512-N3WMsuqV66lT30CrXNbEjx4GEwlow3v6rr4mCcv6prnfwhS01rkgyFdjPNBYd9br7LpXV1+Emh01fHnq2Gdgrw== - tree-kill@^1.2.2: version "1.2.2" resolved "https://registry.npmjs.org/tree-kill/-/tree-kill-1.2.2.tgz" @@ -3677,24 +3619,11 @@ walker@^1.0.8: dependencies: makeerror "1.0.12" -webidl-conversions@^3.0.0: - version "3.0.1" - resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-3.0.1.tgz#24534275e2a7bc6be7bc86611cc16ae0a5654871" - integrity sha512-2JAn3z8AR6rjK8Sm8orRC0h/bcl/DqL7tRPdGZ4I1CjdF+EaMLmYxBHyXuKL849eucPFhvBoxMsflfOb8kxaeQ== - webidl-conversions@^4.0.2: version "4.0.2" resolved "https://registry.yarnpkg.com/webidl-conversions/-/webidl-conversions-4.0.2.tgz#a855980b1f0b6b359ba1d5d9fb39ae941faa63ad" integrity sha512-YQ+BmxuTgd6UXZW3+ICGfyqRyHXVlD5GtQr5+qjiNW7bF0cqrzX500HVXPBOvgXb5YnzDd+h0zqyv61KUD7+Sg== -whatwg-url@^5.0.0: - version "5.0.0" - resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-5.0.0.tgz#966454e8765462e37644d3626f6742ce8b70965d" - integrity sha512-saE57nupxk6v3HY35+jzBwYa0rKSy0XR8JSxZPwgLr7ys0IBzhGviA1/TUGJLmSVqs8pb9AnvICXEuOHLprYTw== - dependencies: - tr46 "~0.0.3" - webidl-conversions "^3.0.0" - whatwg-url@^7.0.0: version "7.1.0" resolved "https://registry.yarnpkg.com/whatwg-url/-/whatwg-url-7.1.0.tgz#c2c492f1eca612988efd3d2266be1b9fc6170d06"