/* tslint:disable */ /* eslint-disable */ /** * Identity Security Cloud API - Work Items * Use these APIs to interact with the Identity Security Cloud platform to achieve repeatable, automated processes with greater scalability. We encourage you to join the SailPoint Developer Community forum at https://developer.sailpoint.com/discuss to connect with other developers using our APIs. * * The version of the OpenAPI document: v1 * * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ import type { Configuration } from '../configuration'; import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios'; import globalAxios from 'axios'; // Some imports not used depending on template conditions // @ts-ignore import { DUMMY_BASE_URL, assertParamExists, setApiKeyToObject, setBasicAuthToObject, setBearerAuthToObject, setOAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from './common'; import type { RequestArgs } from './base'; // @ts-ignore import { BASE_PATH, COLLECTION_FORMATS, BaseAPI, RequiredError, operationServerMap } from './base'; /** * * @export * @interface ApprovalItemDetails */ export interface ApprovalItemDetails { /** * The approval item\'s ID * @type {string} * @memberof ApprovalItemDetails */ 'id'?: string; /** * The account referenced by the approval item * @type {string} * @memberof ApprovalItemDetails */ 'account'?: string | null; /** * The name of the application/source * @type {string} * @memberof ApprovalItemDetails */ 'application'?: string; /** * The attribute\'s name * @type {string} * @memberof ApprovalItemDetails */ 'name'?: string | null; /** * The attribute\'s operation * @type {string} * @memberof ApprovalItemDetails */ 'operation'?: string; /** * The attribute\'s value * @type {string} * @memberof ApprovalItemDetails */ 'value'?: string | null; /** * * @type {WorkItemState} * @memberof ApprovalItemDetails */ 'state'?: WorkItemState; } /** * * @export * @interface ErrorMessageDto */ export interface ErrorMessageDto { /** * The locale for the message text, a BCP 47 language tag. * @type {string} * @memberof ErrorMessageDto */ 'locale'?: string | null; /** * * @type {LocaleOrigin} * @memberof ErrorMessageDto */ 'localeOrigin'?: LocaleOrigin | null; /** * Actual text of the error message in the indicated locale. * @type {string} * @memberof ErrorMessageDto */ 'text'?: string; } /** * * @export * @interface ErrorResponseDto */ export interface ErrorResponseDto { /** * Fine-grained error code providing more detail of the error. * @type {string} * @memberof ErrorResponseDto */ 'detailCode'?: string; /** * Unique tracking id for the error. * @type {string} * @memberof ErrorResponseDto */ 'trackingId'?: string; /** * Generic localized reason for error * @type {Array} * @memberof ErrorResponseDto */ 'messages'?: Array; /** * Plain-text descriptive reasons to provide additional detail to the text provided in the messages field * @type {Array} * @memberof ErrorResponseDto */ 'causes'?: Array; } /** * * @export * @interface FormDetails */ export interface FormDetails { /** * ID of the form * @type {string} * @memberof FormDetails */ 'id'?: string | null; /** * Name of the form * @type {string} * @memberof FormDetails */ 'name'?: string | null; /** * The form title * @type {string} * @memberof FormDetails */ 'title'?: string | null; /** * The form subtitle. * @type {string} * @memberof FormDetails */ 'subtitle'?: string | null; /** * The name of the user that should be shown this form * @type {string} * @memberof FormDetails */ 'targetUser'?: string; /** * Sections of the form * @type {Array} * @memberof FormDetails */ 'sections'?: Array; } /** * * @export * @interface FormItemDetails */ export interface FormItemDetails { /** * Name of the FormItem * @type {string} * @memberof FormItemDetails */ 'name'?: string | null; } /** * * @export * @interface ListWorkItemsV1401Response */ export interface ListWorkItemsV1401Response { /** * A message describing the error * @type {any} * @memberof ListWorkItemsV1401Response */ 'error'?: any; } /** * * @export * @interface ListWorkItemsV1429Response */ export interface ListWorkItemsV1429Response { /** * A message describing the error * @type {any} * @memberof ListWorkItemsV1429Response */ 'message'?: any; } /** * An indicator of how the locale was selected. *DEFAULT* means the locale is the system default. *REQUEST* means the locale was selected from the request context (i.e., best match based on the *Accept-Language* header). Additional values may be added in the future without notice. * @export * @enum {string} */ export const LocaleOrigin = { Default: 'DEFAULT', Request: 'REQUEST' } as const; export type LocaleOrigin = typeof LocaleOrigin[keyof typeof LocaleOrigin]; /** * * @export * @interface RemediationItemDetails */ export interface RemediationItemDetails { /** * The ID of the certification * @type {string} * @memberof RemediationItemDetails */ 'id'?: string; /** * The ID of the certification target * @type {string} * @memberof RemediationItemDetails */ 'targetId'?: string; /** * The name of the certification target * @type {string} * @memberof RemediationItemDetails */ 'targetName'?: string; /** * The display name of the certification target * @type {string} * @memberof RemediationItemDetails */ 'targetDisplayName'?: string; /** * The name of the application/source * @type {string} * @memberof RemediationItemDetails */ 'applicationName'?: string; /** * The name of the attribute being certified * @type {string} * @memberof RemediationItemDetails */ 'attributeName'?: string; /** * The operation of the certification on the attribute * @type {string} * @memberof RemediationItemDetails */ 'attributeOperation'?: string; /** * The value of the attribute being certified * @type {string} * @memberof RemediationItemDetails */ 'attributeValue'?: string; /** * The native identity of the target * @type {string} * @memberof RemediationItemDetails */ 'nativeIdentity'?: string; } /** * * @export * @interface SectionDetails */ export interface SectionDetails { /** * Name of the FormItem * @type {string} * @memberof SectionDetails */ 'name'?: string | null; /** * Label of the section * @type {string} * @memberof SectionDetails */ 'label'?: string | null; /** * List of FormItems. FormItems can be SectionDetails and/or FieldDetails * @type {Array} * @memberof SectionDetails */ 'formItems'?: Array; } /** * * @export * @interface WorkItemForward */ export interface WorkItemForward { /** * The ID of the identity to forward this work item to. * @type {string} * @memberof WorkItemForward */ 'targetOwnerId': string; /** * Comments to send to the target owner * @type {string} * @memberof WorkItemForward */ 'comment': string; /** * If true, send a notification to the target owner. * @type {boolean} * @memberof WorkItemForward */ 'sendNotifications'?: boolean; } /** * The state of a work item * @export * @enum {string} */ export const WorkItemState = { Finished: 'Finished', Rejected: 'Rejected', Returned: 'Returned', Expired: 'Expired', Pending: 'Pending', Canceled: 'Canceled' } as const; export type WorkItemState = typeof WorkItemState[keyof typeof WorkItemState]; /** * The state of a work item * @export * @enum {string} */ export const WorkItemStateManualWorkItems = { Finished: 'Finished', Rejected: 'Rejected', Returned: 'Returned', Expired: 'Expired', Pending: 'Pending', Canceled: 'Canceled' } as const; export type WorkItemStateManualWorkItems = typeof WorkItemStateManualWorkItems[keyof typeof WorkItemStateManualWorkItems]; /** * The type of the work item * @export * @enum {string} */ export const WorkItemTypeManualWorkItems = { Generic: 'Generic', Certification: 'Certification', Remediation: 'Remediation', Delegation: 'Delegation', Approval: 'Approval', ViolationReview: 'ViolationReview', Form: 'Form', PolicyVioloation: 'PolicyVioloation', Challenge: 'Challenge', ImpactAnalysis: 'ImpactAnalysis', Signoff: 'Signoff', Event: 'Event', ManualAction: 'ManualAction', Test: 'Test' } as const; export type WorkItemTypeManualWorkItems = typeof WorkItemTypeManualWorkItems[keyof typeof WorkItemTypeManualWorkItems]; /** * * @export * @interface WorkItems */ export interface WorkItems { /** * ID of the work item * @type {string} * @memberof WorkItems */ 'id'?: string; /** * ID of the requester * @type {string} * @memberof WorkItems */ 'requesterId'?: string | null; /** * The displayname of the requester * @type {string} * @memberof WorkItems */ 'requesterDisplayName'?: string | null; /** * The ID of the owner * @type {string} * @memberof WorkItems */ 'ownerId'?: string | null; /** * The name of the owner * @type {string} * @memberof WorkItems */ 'ownerName'?: string; /** * Time when the work item was created * @type {string} * @memberof WorkItems */ 'created'?: string; /** * Time when the work item was last updated * @type {string} * @memberof WorkItems */ 'modified'?: string | null; /** * The description of the work item * @type {string} * @memberof WorkItems */ 'description'?: string; /** * * @type {WorkItemStateManualWorkItems} * @memberof WorkItems */ 'state'?: WorkItemStateManualWorkItems; /** * * @type {WorkItemTypeManualWorkItems} * @memberof WorkItems */ 'type'?: WorkItemTypeManualWorkItems; /** * A list of remediation items * @type {Array} * @memberof WorkItems */ 'remediationItems'?: Array | null; /** * A list of items that need to be approved * @type {Array} * @memberof WorkItems */ 'approvalItems'?: Array | null; /** * The work item name * @type {string} * @memberof WorkItems */ 'name'?: string | null; /** * The time at which the work item completed * @type {string} * @memberof WorkItems */ 'completed'?: string | null; /** * The number of items in the work item * @type {number} * @memberof WorkItems */ 'numItems'?: number | null; /** * * @type {WorkItemsForm} * @memberof WorkItems */ 'form'?: WorkItemsForm; /** * An array of errors that ocurred during the work item * @type {Array} * @memberof WorkItems */ 'errors'?: Array; } /** * * @export * @interface WorkItemsCount */ export interface WorkItemsCount { /** * The count of work items * @type {number} * @memberof WorkItemsCount */ 'count'?: number; } /** * * @export * @interface WorkItemsForm */ export interface WorkItemsForm { /** * ID of the form * @type {string} * @memberof WorkItemsForm */ 'id'?: string | null; /** * Name of the form * @type {string} * @memberof WorkItemsForm */ 'name'?: string | null; /** * The form title * @type {string} * @memberof WorkItemsForm */ 'title'?: string | null; /** * The form subtitle. * @type {string} * @memberof WorkItemsForm */ 'subtitle'?: string | null; /** * The name of the user that should be shown this form * @type {string} * @memberof WorkItemsForm */ 'targetUser'?: string; /** * Sections of the form * @type {Array} * @memberof WorkItemsForm */ 'sections'?: Array; } /** * * @export * @interface WorkItemsSummary */ export interface WorkItemsSummary { /** * The count of open work items * @type {number} * @memberof WorkItemsSummary */ 'open'?: number; /** * The count of completed work items * @type {number} * @memberof WorkItemsSummary */ 'completed'?: number; /** * The count of total work items * @type {number} * @memberof WorkItemsSummary */ 'total'?: number; } /** * WorkItemsApi - axios parameter creator * @export */ export const WorkItemsApiAxiosParamCreator = function (configuration?: Configuration) { return { /** * This API approves an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Approve an approval item * @param {string} id The ID of the work item * @param {string} approvalItemId The ID of the approval item. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalItemV1: async (id: string, approvalItemId: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('approveApprovalItemV1', 'id', id) // verify required parameter 'approvalItemId' is not null or undefined assertParamExists('approveApprovalItemV1', 'approvalItemId', approvalItemId) const localVarPath = `/work-items/v1/{id}/approve/{approvalItemId}` .replace(`{${"id"}}`, encodeURIComponent(String(id))) .replace(`{${"approvalItemId"}}`, encodeURIComponent(String(approvalItemId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This API bulk approves Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk approve approval items * @param {string} id The ID of the work item * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalItemsInBulkV1: async (id: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('approveApprovalItemsInBulkV1', 'id', id) const localVarPath = `/work-items/v1/bulk-approve/{id}` .replace(`{${"id"}}`, encodeURIComponent(String(id))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This API completes a work item. Either an admin, or the owning/current user must make this request. * @summary Complete a work item * @param {string} id The ID of the work item * @param {string | null} [body] Body is the request payload to create form definition request * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ completeWorkItemV1: async (id: string, body?: string | null, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('completeWorkItemV1', 'id', id) const localVarPath = `/work-items/v1/{id}` .replace(`{${"id"}}`, encodeURIComponent(String(id))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; localVarHeaderParameter['Content-Type'] = 'application/json'; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; localVarRequestOptions.data = serializeDataIfNeeded(body, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This API forwards a work item to a new owner. Either an admin, or the owning/current user must make this request. * @summary Forward a work item * @param {string} id The ID of the work item * @param {WorkItemForward} workItemForward * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ forwardWorkItemV1: async (id: string, workItemForward: WorkItemForward, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('forwardWorkItemV1', 'id', id) // verify required parameter 'workItemForward' is not null or undefined assertParamExists('forwardWorkItemV1', 'workItemForward', workItemForward) const localVarPath = `/work-items/v1/{id}/forward` .replace(`{${"id"}}`, encodeURIComponent(String(id))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; localVarHeaderParameter['Content-Type'] = 'application/json'; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; localVarRequestOptions.data = serializeDataIfNeeded(workItemForward, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This gets a collection of completed work items belonging to either the specified user(admin required), or the current user. * @summary Completed work items * @param {string} [ownerId] The id of the owner of the work item list being requested. Either an admin, or the owning/current user must make this request. * @param {number} [limit] Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {number} [offset] Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {boolean} [count] If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getCompletedWorkItemsV1: async (ownerId?: string, limit?: number, offset?: number, count?: boolean, axiosOptions: RawAxiosRequestConfig = {}): Promise => { const localVarPath = `/work-items/v1/completed`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; if (ownerId !== undefined) { localVarQueryParameter['ownerId'] = ownerId; } if (limit !== undefined) { localVarQueryParameter['limit'] = limit; } if (offset !== undefined) { localVarQueryParameter['offset'] = offset; } if (count !== undefined) { localVarQueryParameter['count'] = count; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This gets a count of completed work items belonging to either the specified user(admin required), or the current user. * @summary Count completed work items * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getCountCompletedWorkItemsV1: async (ownerId?: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { const localVarPath = `/work-items/v1/completed/count`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; if (ownerId !== undefined) { localVarQueryParameter['ownerId'] = ownerId; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This gets a count of work items belonging to either the specified user(admin required), or the current user. * @summary Count work items * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getCountWorkItemsV1: async (ownerId?: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { const localVarPath = `/work-items/v1/count`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; if (ownerId !== undefined) { localVarQueryParameter['ownerId'] = ownerId; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This gets the details of a Work Item belonging to either the specified user(admin required), or the current user. * @summary Get a work item * @param {string} id ID of the work item. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getWorkItemV1: async (id: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('getWorkItemV1', 'id', id) const localVarPath = `/work-items/v1/{id}` .replace(`{${"id"}}`, encodeURIComponent(String(id))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This gets a summary of work items belonging to either the specified user(admin required), or the current user. * @summary Work items summary * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getWorkItemsSummaryV1: async (ownerId?: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { const localVarPath = `/work-items/v1/summary`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; if (ownerId !== undefined) { localVarQueryParameter['ownerId'] = ownerId; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This gets a collection of work items belonging to either the specified user(admin required), or the current user. * @summary List work items * @param {number} [limit] Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {number} [offset] Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {boolean} [count] If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ listWorkItemsV1: async (limit?: number, offset?: number, count?: boolean, ownerId?: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { const localVarPath = `/work-items/v1`; // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'GET', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; if (limit !== undefined) { localVarQueryParameter['limit'] = limit; } if (offset !== undefined) { localVarQueryParameter['offset'] = offset; } if (count !== undefined) { localVarQueryParameter['count'] = count; } if (ownerId !== undefined) { localVarQueryParameter['ownerId'] = ownerId; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This API rejects an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Reject an approval item * @param {string} id The ID of the work item * @param {string} approvalItemId The ID of the approval item. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalItemV1: async (id: string, approvalItemId: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('rejectApprovalItemV1', 'id', id) // verify required parameter 'approvalItemId' is not null or undefined assertParamExists('rejectApprovalItemV1', 'approvalItemId', approvalItemId) const localVarPath = `/work-items/v1/{id}/reject/{approvalItemId}` .replace(`{${"id"}}`, encodeURIComponent(String(id))) .replace(`{${"approvalItemId"}}`, encodeURIComponent(String(approvalItemId))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This API bulk rejects Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk reject approval items * @param {string} id The ID of the work item * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalItemsInBulkV1: async (id: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('rejectApprovalItemsInBulkV1', 'id', id) const localVarPath = `/work-items/v1/bulk-reject/{id}` .replace(`{${"id"}}`, encodeURIComponent(String(id))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * This API submits account selections. Either an admin, or the owning/current user must make this request. * @summary Submit account selections * @param {string} id The ID of the work item * @param {{ [key: string]: any; }} requestBody Account Selection Data map, keyed on fieldName * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ submitAccountSelectionV1: async (id: string, requestBody: { [key: string]: any; }, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('submitAccountSelectionV1', 'id', id) // verify required parameter 'requestBody' is not null or undefined assertParamExists('submitAccountSelectionV1', 'requestBody', requestBody) const localVarPath = `/work-items/v1/{id}/submit-account-selection` .replace(`{${"id"}}`, encodeURIComponent(String(id))); // use dummy base URL string because the URL constructor only accepts absolute URLs. const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); let baseOptions; if (configuration) { baseOptions = configuration.baseOptions; } const localVarRequestOptions = { method: 'POST', ...baseOptions, ...axiosOptions}; const localVarHeaderParameter = {} as any; const localVarQueryParameter = {} as any; localVarHeaderParameter['Content-Type'] = 'application/json'; setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; localVarRequestOptions.data = serializeDataIfNeeded(requestBody, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, } }; /** * WorkItemsApi - functional programming interface * @export */ export const WorkItemsApiFp = function(configuration?: Configuration) { const localVarAxiosParamCreator = WorkItemsApiAxiosParamCreator(configuration) return { /** * This API approves an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Approve an approval item * @param {string} id The ID of the work item * @param {string} approvalItemId The ID of the approval item. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async approveApprovalItemV1(id: string, approvalItemId: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.approveApprovalItemV1(id, approvalItemId, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.approveApprovalItemV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This API bulk approves Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk approve approval items * @param {string} id The ID of the work item * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async approveApprovalItemsInBulkV1(id: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.approveApprovalItemsInBulkV1(id, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.approveApprovalItemsInBulkV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This API completes a work item. Either an admin, or the owning/current user must make this request. * @summary Complete a work item * @param {string} id The ID of the work item * @param {string | null} [body] Body is the request payload to create form definition request * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async completeWorkItemV1(id: string, body?: string | null, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.completeWorkItemV1(id, body, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.completeWorkItemV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This API forwards a work item to a new owner. Either an admin, or the owning/current user must make this request. * @summary Forward a work item * @param {string} id The ID of the work item * @param {WorkItemForward} workItemForward * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async forwardWorkItemV1(id: string, workItemForward: WorkItemForward, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.forwardWorkItemV1(id, workItemForward, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.forwardWorkItemV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This gets a collection of completed work items belonging to either the specified user(admin required), or the current user. * @summary Completed work items * @param {string} [ownerId] The id of the owner of the work item list being requested. Either an admin, or the owning/current user must make this request. * @param {number} [limit] Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {number} [offset] Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {boolean} [count] If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getCompletedWorkItemsV1(ownerId?: string, limit?: number, offset?: number, count?: boolean, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { const localVarAxiosArgs = await localVarAxiosParamCreator.getCompletedWorkItemsV1(ownerId, limit, offset, count, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.getCompletedWorkItemsV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This gets a count of completed work items belonging to either the specified user(admin required), or the current user. * @summary Count completed work items * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getCountCompletedWorkItemsV1(ownerId?: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getCountCompletedWorkItemsV1(ownerId, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.getCountCompletedWorkItemsV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This gets a count of work items belonging to either the specified user(admin required), or the current user. * @summary Count work items * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getCountWorkItemsV1(ownerId?: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getCountWorkItemsV1(ownerId, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.getCountWorkItemsV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This gets the details of a Work Item belonging to either the specified user(admin required), or the current user. * @summary Get a work item * @param {string} id ID of the work item. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getWorkItemV1(id: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getWorkItemV1(id, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.getWorkItemV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This gets a summary of work items belonging to either the specified user(admin required), or the current user. * @summary Work items summary * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getWorkItemsSummaryV1(ownerId?: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getWorkItemsSummaryV1(ownerId, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.getWorkItemsSummaryV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This gets a collection of work items belonging to either the specified user(admin required), or the current user. * @summary List work items * @param {number} [limit] Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {number} [offset] Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {boolean} [count] If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @param {string} [ownerId] ID of the work item owner. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async listWorkItemsV1(limit?: number, offset?: number, count?: boolean, ownerId?: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { const localVarAxiosArgs = await localVarAxiosParamCreator.listWorkItemsV1(limit, offset, count, ownerId, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.listWorkItemsV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This API rejects an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Reject an approval item * @param {string} id The ID of the work item * @param {string} approvalItemId The ID of the approval item. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async rejectApprovalItemV1(id: string, approvalItemId: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.rejectApprovalItemV1(id, approvalItemId, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.rejectApprovalItemV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This API bulk rejects Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk reject approval items * @param {string} id The ID of the work item * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async rejectApprovalItemsInBulkV1(id: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.rejectApprovalItemsInBulkV1(id, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.rejectApprovalItemsInBulkV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * This API submits account selections. Either an admin, or the owning/current user must make this request. * @summary Submit account selections * @param {string} id The ID of the work item * @param {{ [key: string]: any; }} requestBody Account Selection Data map, keyed on fieldName * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async submitAccountSelectionV1(id: string, requestBody: { [key: string]: any; }, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.submitAccountSelectionV1(id, requestBody, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['WorkItemsApi.submitAccountSelectionV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, } }; /** * WorkItemsApi - factory interface * @export */ export const WorkItemsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { const localVarFp = WorkItemsApiFp(configuration) return { /** * This API approves an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Approve an approval item * @param {WorkItemsApiApproveApprovalItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalItemV1(requestParameters: WorkItemsApiApproveApprovalItemV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.approveApprovalItemV1(requestParameters.id, requestParameters.approvalItemId, axiosOptions).then((request) => request(axios, basePath)); }, /** * This API bulk approves Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk approve approval items * @param {WorkItemsApiApproveApprovalItemsInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalItemsInBulkV1(requestParameters: WorkItemsApiApproveApprovalItemsInBulkV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.approveApprovalItemsInBulkV1(requestParameters.id, axiosOptions).then((request) => request(axios, basePath)); }, /** * This API completes a work item. Either an admin, or the owning/current user must make this request. * @summary Complete a work item * @param {WorkItemsApiCompleteWorkItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ completeWorkItemV1(requestParameters: WorkItemsApiCompleteWorkItemV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.completeWorkItemV1(requestParameters.id, requestParameters.body, axiosOptions).then((request) => request(axios, basePath)); }, /** * This API forwards a work item to a new owner. Either an admin, or the owning/current user must make this request. * @summary Forward a work item * @param {WorkItemsApiForwardWorkItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ forwardWorkItemV1(requestParameters: WorkItemsApiForwardWorkItemV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.forwardWorkItemV1(requestParameters.id, requestParameters.workItemForward, axiosOptions).then((request) => request(axios, basePath)); }, /** * This gets a collection of completed work items belonging to either the specified user(admin required), or the current user. * @summary Completed work items * @param {WorkItemsApiGetCompletedWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getCompletedWorkItemsV1(requestParameters: WorkItemsApiGetCompletedWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig): AxiosPromise> { return localVarFp.getCompletedWorkItemsV1(requestParameters.ownerId, requestParameters.limit, requestParameters.offset, requestParameters.count, axiosOptions).then((request) => request(axios, basePath)); }, /** * This gets a count of completed work items belonging to either the specified user(admin required), or the current user. * @summary Count completed work items * @param {WorkItemsApiGetCountCompletedWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getCountCompletedWorkItemsV1(requestParameters: WorkItemsApiGetCountCompletedWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getCountCompletedWorkItemsV1(requestParameters.ownerId, axiosOptions).then((request) => request(axios, basePath)); }, /** * This gets a count of work items belonging to either the specified user(admin required), or the current user. * @summary Count work items * @param {WorkItemsApiGetCountWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getCountWorkItemsV1(requestParameters: WorkItemsApiGetCountWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getCountWorkItemsV1(requestParameters.ownerId, axiosOptions).then((request) => request(axios, basePath)); }, /** * This gets the details of a Work Item belonging to either the specified user(admin required), or the current user. * @summary Get a work item * @param {WorkItemsApiGetWorkItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getWorkItemV1(requestParameters: WorkItemsApiGetWorkItemV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getWorkItemV1(requestParameters.id, axiosOptions).then((request) => request(axios, basePath)); }, /** * This gets a summary of work items belonging to either the specified user(admin required), or the current user. * @summary Work items summary * @param {WorkItemsApiGetWorkItemsSummaryV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getWorkItemsSummaryV1(requestParameters: WorkItemsApiGetWorkItemsSummaryV1Request = {}, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getWorkItemsSummaryV1(requestParameters.ownerId, axiosOptions).then((request) => request(axios, basePath)); }, /** * This gets a collection of work items belonging to either the specified user(admin required), or the current user. * @summary List work items * @param {WorkItemsApiListWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ listWorkItemsV1(requestParameters: WorkItemsApiListWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig): AxiosPromise> { return localVarFp.listWorkItemsV1(requestParameters.limit, requestParameters.offset, requestParameters.count, requestParameters.ownerId, axiosOptions).then((request) => request(axios, basePath)); }, /** * This API rejects an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Reject an approval item * @param {WorkItemsApiRejectApprovalItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalItemV1(requestParameters: WorkItemsApiRejectApprovalItemV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.rejectApprovalItemV1(requestParameters.id, requestParameters.approvalItemId, axiosOptions).then((request) => request(axios, basePath)); }, /** * This API bulk rejects Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk reject approval items * @param {WorkItemsApiRejectApprovalItemsInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalItemsInBulkV1(requestParameters: WorkItemsApiRejectApprovalItemsInBulkV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.rejectApprovalItemsInBulkV1(requestParameters.id, axiosOptions).then((request) => request(axios, basePath)); }, /** * This API submits account selections. Either an admin, or the owning/current user must make this request. * @summary Submit account selections * @param {WorkItemsApiSubmitAccountSelectionV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ submitAccountSelectionV1(requestParameters: WorkItemsApiSubmitAccountSelectionV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.submitAccountSelectionV1(requestParameters.id, requestParameters.requestBody, axiosOptions).then((request) => request(axios, basePath)); }, }; }; /** * Request parameters for approveApprovalItemV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiApproveApprovalItemV1Request */ export interface WorkItemsApiApproveApprovalItemV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiApproveApprovalItemV1 */ readonly id: string /** * The ID of the approval item. * @type {string} * @memberof WorkItemsApiApproveApprovalItemV1 */ readonly approvalItemId: string } /** * Request parameters for approveApprovalItemsInBulkV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiApproveApprovalItemsInBulkV1Request */ export interface WorkItemsApiApproveApprovalItemsInBulkV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiApproveApprovalItemsInBulkV1 */ readonly id: string } /** * Request parameters for completeWorkItemV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiCompleteWorkItemV1Request */ export interface WorkItemsApiCompleteWorkItemV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiCompleteWorkItemV1 */ readonly id: string /** * Body is the request payload to create form definition request * @type {string} * @memberof WorkItemsApiCompleteWorkItemV1 */ readonly body?: string | null } /** * Request parameters for forwardWorkItemV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiForwardWorkItemV1Request */ export interface WorkItemsApiForwardWorkItemV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiForwardWorkItemV1 */ readonly id: string /** * * @type {WorkItemForward} * @memberof WorkItemsApiForwardWorkItemV1 */ readonly workItemForward: WorkItemForward } /** * Request parameters for getCompletedWorkItemsV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiGetCompletedWorkItemsV1Request */ export interface WorkItemsApiGetCompletedWorkItemsV1Request { /** * The id of the owner of the work item list being requested. Either an admin, or the owning/current user must make this request. * @type {string} * @memberof WorkItemsApiGetCompletedWorkItemsV1 */ readonly ownerId?: string /** * Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @type {number} * @memberof WorkItemsApiGetCompletedWorkItemsV1 */ readonly limit?: number /** * Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @type {number} * @memberof WorkItemsApiGetCompletedWorkItemsV1 */ readonly offset?: number /** * If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @type {boolean} * @memberof WorkItemsApiGetCompletedWorkItemsV1 */ readonly count?: boolean } /** * Request parameters for getCountCompletedWorkItemsV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiGetCountCompletedWorkItemsV1Request */ export interface WorkItemsApiGetCountCompletedWorkItemsV1Request { /** * ID of the work item owner. * @type {string} * @memberof WorkItemsApiGetCountCompletedWorkItemsV1 */ readonly ownerId?: string } /** * Request parameters for getCountWorkItemsV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiGetCountWorkItemsV1Request */ export interface WorkItemsApiGetCountWorkItemsV1Request { /** * ID of the work item owner. * @type {string} * @memberof WorkItemsApiGetCountWorkItemsV1 */ readonly ownerId?: string } /** * Request parameters for getWorkItemV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiGetWorkItemV1Request */ export interface WorkItemsApiGetWorkItemV1Request { /** * ID of the work item. * @type {string} * @memberof WorkItemsApiGetWorkItemV1 */ readonly id: string } /** * Request parameters for getWorkItemsSummaryV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiGetWorkItemsSummaryV1Request */ export interface WorkItemsApiGetWorkItemsSummaryV1Request { /** * ID of the work item owner. * @type {string} * @memberof WorkItemsApiGetWorkItemsSummaryV1 */ readonly ownerId?: string } /** * Request parameters for listWorkItemsV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiListWorkItemsV1Request */ export interface WorkItemsApiListWorkItemsV1Request { /** * Max number of results to return. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @type {number} * @memberof WorkItemsApiListWorkItemsV1 */ readonly limit?: number /** * Offset into the full result set. Usually specified with *limit* to paginate through the results. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @type {number} * @memberof WorkItemsApiListWorkItemsV1 */ readonly offset?: number /** * If *true* it will populate the *X-Total-Count* response header with the number of results that would be returned if *limit* and *offset* were ignored. Since requesting a total count can have a performance impact, it is recommended not to send **count=true** if that value will not be used. See [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters) for more information. * @type {boolean} * @memberof WorkItemsApiListWorkItemsV1 */ readonly count?: boolean /** * ID of the work item owner. * @type {string} * @memberof WorkItemsApiListWorkItemsV1 */ readonly ownerId?: string } /** * Request parameters for rejectApprovalItemV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiRejectApprovalItemV1Request */ export interface WorkItemsApiRejectApprovalItemV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiRejectApprovalItemV1 */ readonly id: string /** * The ID of the approval item. * @type {string} * @memberof WorkItemsApiRejectApprovalItemV1 */ readonly approvalItemId: string } /** * Request parameters for rejectApprovalItemsInBulkV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiRejectApprovalItemsInBulkV1Request */ export interface WorkItemsApiRejectApprovalItemsInBulkV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiRejectApprovalItemsInBulkV1 */ readonly id: string } /** * Request parameters for submitAccountSelectionV1 operation in WorkItemsApi. * @export * @interface WorkItemsApiSubmitAccountSelectionV1Request */ export interface WorkItemsApiSubmitAccountSelectionV1Request { /** * The ID of the work item * @type {string} * @memberof WorkItemsApiSubmitAccountSelectionV1 */ readonly id: string /** * Account Selection Data map, keyed on fieldName * @type {{ [key: string]: any; }} * @memberof WorkItemsApiSubmitAccountSelectionV1 */ readonly requestBody: { [key: string]: any; } } /** * WorkItemsApi - object-oriented interface * @export * @class WorkItemsApi * @extends {BaseAPI} */ export class WorkItemsApi extends BaseAPI { /** * This API approves an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Approve an approval item * @param {WorkItemsApiApproveApprovalItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public approveApprovalItemV1(requestParameters: WorkItemsApiApproveApprovalItemV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).approveApprovalItemV1(requestParameters.id, requestParameters.approvalItemId, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This API bulk approves Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk approve approval items * @param {WorkItemsApiApproveApprovalItemsInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public approveApprovalItemsInBulkV1(requestParameters: WorkItemsApiApproveApprovalItemsInBulkV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).approveApprovalItemsInBulkV1(requestParameters.id, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This API completes a work item. Either an admin, or the owning/current user must make this request. * @summary Complete a work item * @param {WorkItemsApiCompleteWorkItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public completeWorkItemV1(requestParameters: WorkItemsApiCompleteWorkItemV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).completeWorkItemV1(requestParameters.id, requestParameters.body, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This API forwards a work item to a new owner. Either an admin, or the owning/current user must make this request. * @summary Forward a work item * @param {WorkItemsApiForwardWorkItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public forwardWorkItemV1(requestParameters: WorkItemsApiForwardWorkItemV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).forwardWorkItemV1(requestParameters.id, requestParameters.workItemForward, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This gets a collection of completed work items belonging to either the specified user(admin required), or the current user. * @summary Completed work items * @param {WorkItemsApiGetCompletedWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public getCompletedWorkItemsV1(requestParameters: WorkItemsApiGetCompletedWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).getCompletedWorkItemsV1(requestParameters.ownerId, requestParameters.limit, requestParameters.offset, requestParameters.count, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This gets a count of completed work items belonging to either the specified user(admin required), or the current user. * @summary Count completed work items * @param {WorkItemsApiGetCountCompletedWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public getCountCompletedWorkItemsV1(requestParameters: WorkItemsApiGetCountCompletedWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).getCountCompletedWorkItemsV1(requestParameters.ownerId, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This gets a count of work items belonging to either the specified user(admin required), or the current user. * @summary Count work items * @param {WorkItemsApiGetCountWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public getCountWorkItemsV1(requestParameters: WorkItemsApiGetCountWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).getCountWorkItemsV1(requestParameters.ownerId, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This gets the details of a Work Item belonging to either the specified user(admin required), or the current user. * @summary Get a work item * @param {WorkItemsApiGetWorkItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public getWorkItemV1(requestParameters: WorkItemsApiGetWorkItemV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).getWorkItemV1(requestParameters.id, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This gets a summary of work items belonging to either the specified user(admin required), or the current user. * @summary Work items summary * @param {WorkItemsApiGetWorkItemsSummaryV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public getWorkItemsSummaryV1(requestParameters: WorkItemsApiGetWorkItemsSummaryV1Request = {}, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).getWorkItemsSummaryV1(requestParameters.ownerId, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This gets a collection of work items belonging to either the specified user(admin required), or the current user. * @summary List work items * @param {WorkItemsApiListWorkItemsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public listWorkItemsV1(requestParameters: WorkItemsApiListWorkItemsV1Request = {}, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).listWorkItemsV1(requestParameters.limit, requestParameters.offset, requestParameters.count, requestParameters.ownerId, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This API rejects an Approval Item. Either an admin, or the owning/current user must make this request. * @summary Reject an approval item * @param {WorkItemsApiRejectApprovalItemV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public rejectApprovalItemV1(requestParameters: WorkItemsApiRejectApprovalItemV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).rejectApprovalItemV1(requestParameters.id, requestParameters.approvalItemId, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This API bulk rejects Approval Items. Either an admin, or the owning/current user must make this request. * @summary Bulk reject approval items * @param {WorkItemsApiRejectApprovalItemsInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public rejectApprovalItemsInBulkV1(requestParameters: WorkItemsApiRejectApprovalItemsInBulkV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).rejectApprovalItemsInBulkV1(requestParameters.id, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * This API submits account selections. Either an admin, or the owning/current user must make this request. * @summary Submit account selections * @param {WorkItemsApiSubmitAccountSelectionV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof WorkItemsApi */ public submitAccountSelectionV1(requestParameters: WorkItemsApiSubmitAccountSelectionV1Request, axiosOptions?: RawAxiosRequestConfig) { return WorkItemsApiFp(this.configuration).submitAccountSelectionV1(requestParameters.id, requestParameters.requestBody, axiosOptions).then((request) => request(this.axios, this.basePath)); } }