Skip to content

Function: getBulkOperationProgress() ​

ts
function getBulkOperationProgress(
   client, 
   parameters, 
   options?
): Promise<{
[key: string]: unknown;
  created?: Date;
  failedAccessibleIssues?: Record<string, string[]>;
  invalidOrInaccessibleIssueCount?: number;
  processedAccessibleIssues?: number[];
  progressPercent?: number;
  started?: Date;
  status?:   | string & object
     | "ENQUEUED"
     | "RUNNING"
     | "COMPLETE"
     | "FAILED"
     | "CANCEL_REQUESTED"
     | "CANCELLED"
     | "DEAD";
  submittedBy?: {
   [key: string]: unknown;
     accountId?: string;
     accountType?: "unknown" | string & object | "atlassian" | "app" | "customer";
     active?: boolean;
     applicationRoles?: {
      [key: string]: unknown;
        callback?: {
         [key: string]: unknown;
        };
        items?: object[];
        max-results?: number;
        pagingCallback?: {
         [key: string]: unknown;
        };
        size?: number;
     };
     appType?: string;
     avatarUrls?: {
      [key: string]: unknown;
        16x16?: string;
        24x24?: string;
        32x32?: string;
        48x48?: string;
     };
     displayName?: string;
     emailAddress?: string;
     expand?: string;
     groups?: {
      [key: string]: unknown;
        callback?: {
         [key: string]: unknown;
        };
        items?: object[];
        max-results?: number;
        pagingCallback?: {
         [key: string]: unknown;
        };
        size?: number;
     };
     guest?: boolean;
     locale?: string;
     self?: string;
     timeZone?: string;
  };
  taskId?: string;
  totalIssueCount?: number;
  updated?: Date;
}>;

Defined in: src/cloud/api/issueBulkOperations.ts:366

Use this to get the progress state for the specified bulk operation taskId.

Permissions required:

If the task is running, this resource will return:

\{
  "taskId": "10779",
  "status": "RUNNING",
  "progressPercent": 65,
  "submittedBy": \{ "accountId": "5b10a2844c20165700ede21g" \},
  "created": 1690180055963,
  "started": 1690180056206,
  "updated": 169018005829
\}

If the task has completed, then this resource will return:

\{
  "processedAccessibleIssues": [10001, 10002],
  "created": 1709189449954,
  "progressPercent": 100,
  "started": 1709189450154,
  "status": "COMPLETE",
  "submittedBy": \{ "accountId": "5b10a2844c20165700ede21g" \},
  "invalidOrInaccessibleIssueCount": 0,
  "taskId": "10000",
  "totalIssueCount": 2,
  "updated": 1709189450354
\}

Note: You can view task progress for up to 14 days from creation.

Parameters ​

ParameterTypeDescription
clientClient-
parameters{ taskId: string; }-
parameters.taskIdstringThe ID of the task.
options?RequestOptions-

Returns ​

Promise<{ [key: string]: unknown; created?: Date; failedAccessibleIssues?: Record<string, string[]>; invalidOrInaccessibleIssueCount?: number; processedAccessibleIssues?: number[]; progressPercent?: number; started?: Date; status?: | string & object | "ENQUEUED" | "RUNNING" | "COMPLETE" | "FAILED" | "CANCEL_REQUESTED" | "CANCELLED" | "DEAD"; submittedBy?: { [key: string]: unknown; accountId?: string; accountType?: "unknown" | string & object | "atlassian" | "app" | "customer"; active?: boolean; applicationRoles?: { [key: string]: unknown; callback?: { [key: string]: unknown; }; items?: object[]; max-results?: number; pagingCallback?: { [key: string]: unknown; }; size?: number; }; appType?: string; avatarUrls?: { [key: string]: unknown; 16x16?: string; 24x24?: string; 32x32?: string; 48x48?: string; }; displayName?: string; emailAddress?: string; expand?: string; groups?: { [key: string]: unknown; callback?: { [key: string]: unknown; }; items?: object[]; max-results?: number; pagingCallback?: { [key: string]: unknown; }; size?: number; }; guest?: boolean; locale?: string; self?: string; timeZone?: string; }; taskId?: string; totalIssueCount?: number; updated?: Date; }>