/* tslint:disable */ /* eslint-disable */ /** * Identity Security Cloud API - Approvals * 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'; /** * Approval Object * @export * @interface Approval2 */ export interface Approval2 { /** * The Approval ID * @type {string} * @memberof Approval2 */ 'id'?: string; /** * The Tenant ID of the Approval * @type {string} * @memberof Approval2 */ 'tenantId'?: string; /** * The type of the approval, such as ENTITLEMENT_DESCRIPTIONS, CUSTOM_ACCESS_REQUEST_APPROVAL, GENERIC_APPROVAL * @type {string} * @memberof Approval2 */ 'type'?: string; /** * Object representation of an approver of an approval * @type {Array} * @memberof Approval2 */ 'approvers'?: Array; /** * Date the approval was created * @type {string} * @memberof Approval2 */ 'createdDate'?: string; /** * Date the approval is due * @type {string} * @memberof Approval2 */ 'dueDate'?: string; /** * Step in the escalation process. If set to 0, the approval is not escalated. If set to 1, the approval is escalated to the first approver in the escalation chain. * @type {string} * @memberof Approval2 */ 'escalationStep'?: string; /** * The serial step of the approval in the approval chain. For example, serialStep 1 is the first approval to action in an approval request chain. Parallel approvals are set to 0. * @type {number} * @memberof Approval2 */ 'serialStep'?: number; /** * Whether or not the approval has been escalated. Will reset to false when the approval is actioned on. * @type {boolean} * @memberof Approval2 */ 'isEscalated'?: boolean; /** * The name of the approval for a given locale * @type {Array} * @memberof Approval2 */ 'name'?: Array; /** * * @type {ApprovalBatch} * @memberof Approval2 */ 'batchRequest'?: ApprovalBatch; /** * * @type {ApprovalConfig} * @memberof Approval2 */ 'approvalConfig'?: ApprovalConfig; /** * The description of the approval for a given locale * @type {Array} * @memberof Approval2 */ 'description'?: Array; /** * Signifies what medium to use when sending notifications (currently only email is utilized) * @type {string} * @memberof Approval2 */ 'medium'?: Approval2MediumEnum; /** * The priority of the approval * @type {string} * @memberof Approval2 */ 'priority'?: Approval2PriorityEnum; /** * * @type {ApprovalIdentity} * @memberof Approval2 */ 'requester'?: ApprovalIdentity; /** * * @type {ApprovalIdentity} * @memberof Approval2 */ 'requestee'?: ApprovalIdentity; /** * Object representation of a comment on the approval * @type {Array} * @memberof Approval2 */ 'comments'?: Array; /** * Array of approvers who have approved the approval * @type {Array} * @memberof Approval2 */ 'approvedBy'?: Array; /** * Array of approvers who have rejected the approval * @type {Array} * @memberof Approval2 */ 'rejectedBy'?: Array; /** * Array of identities that the approval request is currently assigned to/waiting on. For parallel approvals, this is set to all approvers left to approve. * @type {Array} * @memberof Approval2 */ 'assignedTo'?: Array; /** * Date the approval was completed * @type {string} * @memberof Approval2 */ 'completedDate'?: string; /** * * @type {Approval2ApprovalCriteria} * @memberof Approval2 */ 'approvalCriteria'?: Approval2ApprovalCriteria; /** * Json string representing additional attributes known about the object to be approved. * @type {string} * @memberof Approval2 */ 'additionalAttributes'?: string; /** * Reference data related to the approval * @type {Array} * @memberof Approval2 */ 'referenceData'?: Array; /** * History of whom the approval request was assigned to * @type {Array} * @memberof Approval2 */ 'reassignmentHistory'?: Array; /** * Field that can include any static additional info that may be needed by the service that the approval request originated from * @type {{ [key: string]: any; }} * @memberof Approval2 */ 'staticAttributes'?: { [key: string]: any; }; /** * Date/time that the approval request was last updated * @type {string} * @memberof Approval2 */ 'modifiedDate'?: string; /** * RequestedTarget used to specify the actual object or target the approval request is for * @type {Array} * @memberof Approval2 */ 'requestedTarget'?: Array; } export const Approval2MediumEnum = { Email: 'EMAIL', Slack: 'SLACK', Teams: 'TEAMS' } as const; export type Approval2MediumEnum = typeof Approval2MediumEnum[keyof typeof Approval2MediumEnum]; export const Approval2PriorityEnum = { High: 'HIGH', Medium: 'MEDIUM', Low: 'LOW' } as const; export type Approval2PriorityEnum = typeof Approval2PriorityEnum[keyof typeof Approval2PriorityEnum]; /** * Criteria that needs to be met for an approval or rejection * @export * @interface Approval2ApprovalCriteria */ export interface Approval2ApprovalCriteria { /** * Type of approval criteria, such as SERIAL or PARALLEL * @type {string} * @memberof Approval2ApprovalCriteria */ 'type'?: string; /** * * @type {Approval2ApprovalCriteriaApproval} * @memberof Approval2ApprovalCriteria */ 'approval'?: Approval2ApprovalCriteriaApproval; /** * * @type {Approval2ApprovalCriteriaRejection} * @memberof Approval2ApprovalCriteria */ 'rejection'?: Approval2ApprovalCriteriaRejection; } /** * Criteria for approval * @export * @interface Approval2ApprovalCriteriaApproval */ export interface Approval2ApprovalCriteriaApproval { /** * This defines what the field \"value\" will be used as, either a count or percentage of the total approvers that need to approve * @type {string} * @memberof Approval2ApprovalCriteriaApproval */ 'calculationType'?: Approval2ApprovalCriteriaApprovalCalculationTypeEnum; /** * The value that needs to be met for the approval criteria * @type {number} * @memberof Approval2ApprovalCriteriaApproval */ 'value'?: number; } export const Approval2ApprovalCriteriaApprovalCalculationTypeEnum = { Count: 'COUNT', Percent: 'PERCENT' } as const; export type Approval2ApprovalCriteriaApprovalCalculationTypeEnum = typeof Approval2ApprovalCriteriaApprovalCalculationTypeEnum[keyof typeof Approval2ApprovalCriteriaApprovalCalculationTypeEnum]; /** * Criteria for rejection * @export * @interface Approval2ApprovalCriteriaRejection */ export interface Approval2ApprovalCriteriaRejection { /** * This defines what the field \"value\" will be used as, either a count or percentage of the total approvers that need to reject * @type {string} * @memberof Approval2ApprovalCriteriaRejection */ 'calculationType'?: Approval2ApprovalCriteriaRejectionCalculationTypeEnum; /** * The value that needs to be met for the rejection criteria * @type {number} * @memberof Approval2ApprovalCriteriaRejection */ 'value'?: number; } export const Approval2ApprovalCriteriaRejectionCalculationTypeEnum = { Count: 'COUNT', Percent: 'PERCENT' } as const; export type Approval2ApprovalCriteriaRejectionCalculationTypeEnum = typeof Approval2ApprovalCriteriaRejectionCalculationTypeEnum[keyof typeof Approval2ApprovalCriteriaRejectionCalculationTypeEnum]; /** * Approval Approve Request * @export * @interface ApprovalApproveRequest */ export interface ApprovalApproveRequest { /** * Additional attributes as key-value pairs that are not part of the standard schema but can be included for custom data. * @type {{ [key: string]: string; }} * @memberof ApprovalApproveRequest */ 'additionalAttributes'?: { [key: string]: string; }; /** * Comment associated with the request. * @type {string} * @memberof ApprovalApproveRequest */ 'comment'?: string; } /** * Approval Attributes Request * @export * @interface ApprovalAttributesRequest */ export interface ApprovalAttributesRequest { /** * Additional attributes as key-value pairs that are not part of the standard schema but can be included for custom data. * @type {{ [key: string]: string; }} * @memberof ApprovalAttributesRequest */ 'additionalAttributes'?: { [key: string]: string; }; /** * Comment associated with the request. * @type {string} * @memberof ApprovalAttributesRequest */ 'comment'?: string; /** * List of attribute keys to be removed. * @type {Array} * @memberof ApprovalAttributesRequest */ 'removeAttributeKeys'?: Array; } /** * Batch properties if an approval is sent via batching. * @export * @interface ApprovalBatch */ export interface ApprovalBatch { /** * ID of the batch * @type {string} * @memberof ApprovalBatch */ 'batchId'?: string; /** * How many approvals are going to be in this batch. Defaults to 1 if not provided. * @type {number} * @memberof ApprovalBatch */ 'batchSize'?: number; } /** * Request body for cancelling a single approval request. * @export * @interface ApprovalCancelRequest */ export interface ApprovalCancelRequest { /** * Optional comment associated with the cancel request. * @type {string} * @memberof ApprovalCancelRequest */ 'comment'?: string; } /** * Comments Object * @export * @interface ApprovalComment3 */ export interface ApprovalComment3 { /** * * @type {ApprovalIdentity} * @memberof ApprovalComment3 */ 'author'?: ApprovalIdentity; /** * Comment to be left on an approval * @type {string} * @memberof ApprovalComment3 */ 'comment'?: string; /** * Date the comment was created * @type {string} * @memberof ApprovalComment3 */ 'createdDate'?: string; /** * ID of the comment * @type {string} * @memberof ApprovalComment3 */ 'commentId'?: string; } /** * * @export * @interface ApprovalCommentsRequest */ export interface ApprovalCommentsRequest { /** * Comment associated with the request. * @type {string} * @memberof ApprovalCommentsRequest */ 'comment'?: string; } /** * Approval config Object * @export * @interface ApprovalConfig */ export interface ApprovalConfig { /** * * @type {ApprovalConfigReminderConfig} * @memberof ApprovalConfig */ 'reminderConfig'?: ApprovalConfigReminderConfig; /** * * @type {ApprovalConfigEscalationConfig} * @memberof ApprovalConfig */ 'escalationConfig'?: ApprovalConfigEscalationConfig; /** * * @type {ApprovalConfigTimeoutConfig} * @memberof ApprovalConfig */ 'timeoutConfig'?: ApprovalConfigTimeoutConfig; /** * * @type {ApprovalConfigCronTimezone} * @memberof ApprovalConfig */ 'cronTimezone'?: ApprovalConfigCronTimezone; /** * If the approval request has an approvalCriteria of SERIAL this chain will be used to determine the assignment order. * @type {Array} * @memberof ApprovalConfig */ 'serialChain'?: Array; /** * Determines whether a comment is required when approving or rejecting the approval request. * @type {string} * @memberof ApprovalConfig */ 'requiresComment'?: ApprovalConfigRequiresCommentEnum; /** * * @type {ApprovalConfigFallbackApprover} * @memberof ApprovalConfig */ 'fallbackApprover'?: ApprovalConfigFallbackApprover; /** * Specifies how to treat the identity type \"MANAGER_OF\" when the requestee is a machine identity. * @type {string} * @memberof ApprovalConfig */ 'machineIdentityManagerAssignment'?: ApprovalConfigMachineIdentityManagerAssignmentEnum; /** * When true, all approvals will be created with the status \"PASSED\". * @type {boolean} * @memberof ApprovalConfig */ 'circumventApprovalProcess'?: boolean; /** * OFF will prevent the approval request from being assigned to the requester or requestee by assigning it to their manager instead. DIRECT will cause approval requests to be auto-approved when assigned directly and only to the requester. INDIRECT will auto-approve when the requester appears anywhere in the list of approvers, including in a governance group. This field will only be effective if requestedTarget.reauthRequired is set to false, otherwise the approval will have to be manually approved. * @type {string} * @memberof ApprovalConfig */ 'autoApprove'?: ApprovalConfigAutoApproveEnum; } export const ApprovalConfigRequiresCommentEnum = { Approval: 'APPROVAL', Rejection: 'REJECTION', All: 'ALL', Off: 'OFF' } as const; export type ApprovalConfigRequiresCommentEnum = typeof ApprovalConfigRequiresCommentEnum[keyof typeof ApprovalConfigRequiresCommentEnum]; export const ApprovalConfigMachineIdentityManagerAssignmentEnum = { ManagerOfRequester: 'MANAGER_OF_REQUESTER', MachineIdentityOwner: 'MACHINE_IDENTITY_OWNER', ManagerOfMachineIdentityOwner: 'MANAGER_OF_MACHINE_IDENTITY_OWNER', RequestedTargetOwner: 'REQUESTED_TARGET_OWNER', ManagerOfRequestedTargetOwner: 'MANAGER_OF_REQUESTED_TARGET_OWNER', AccountOwner: 'ACCOUNT_OWNER', ManagerOfAccountOwner: 'MANAGER_OF_ACCOUNT_OWNER' } as const; export type ApprovalConfigMachineIdentityManagerAssignmentEnum = typeof ApprovalConfigMachineIdentityManagerAssignmentEnum[keyof typeof ApprovalConfigMachineIdentityManagerAssignmentEnum]; export const ApprovalConfigAutoApproveEnum = { Off: 'OFF', Direct: 'DIRECT', Indirect: 'INDIRECT' } as const; export type ApprovalConfigAutoApproveEnum = typeof ApprovalConfigAutoApproveEnum[keyof typeof ApprovalConfigAutoApproveEnum]; /** * Timezone configuration for cron schedules. * @export * @interface ApprovalConfigCronTimezone */ export interface ApprovalConfigCronTimezone { /** * Timezone location for cron schedules. * @type {string} * @memberof ApprovalConfigCronTimezone */ 'location'?: string; /** * Timezone offset for cron schedules. * @type {string} * @memberof ApprovalConfigCronTimezone */ 'offset'?: string; } /** * Configuration for escalations. * @export * @interface ApprovalConfigEscalationConfig */ export interface ApprovalConfigEscalationConfig { /** * Indicates if escalations are enabled. * @type {boolean} * @memberof ApprovalConfigEscalationConfig */ 'enabled'?: boolean; /** * Number of days until the first escalation. * @type {number} * @memberof ApprovalConfigEscalationConfig */ 'daysUntilFirstEscalation'?: number; /** * Cron schedule for escalations. * @type {string} * @memberof ApprovalConfigEscalationConfig */ 'escalationCronSchedule'?: string; /** * Escalation chain configuration. * @type {Array} * @memberof ApprovalConfigEscalationConfig */ 'escalationChain'?: Array; } /** * * @export * @interface ApprovalConfigEscalationConfigEscalationChainInner */ export interface ApprovalConfigEscalationConfigEscalationChainInner { /** * Starting at 1 defines the order in which the identities will get assigned * @type {number} * @memberof ApprovalConfigEscalationConfigEscalationChainInner */ 'tier'?: number; /** * Optional Identity ID of the type of identity defined in the \'identityType\' field. * @type {string} * @memberof ApprovalConfigEscalationConfigEscalationChainInner */ 'identityId'?: string; /** * Type of identityId in the escalation chain. * @type {string} * @memberof ApprovalConfigEscalationConfigEscalationChainInner */ 'identityType'?: ApprovalConfigEscalationConfigEscalationChainInnerIdentityTypeEnum; } export const ApprovalConfigEscalationConfigEscalationChainInnerIdentityTypeEnum = { Identity: 'IDENTITY', ManagerOf: 'MANAGER_OF', AccountOwner: 'ACCOUNT_OWNER', MachineAccountOwner: 'MACHINE_ACCOUNT_OWNER', MachineIdentityOwner: 'MACHINE_IDENTITY_OWNER', ManagerOfRequestedTargetOwner: 'MANAGER_OF_REQUESTED_TARGET_OWNER', ManagerOfMachineIdentityOwner: 'MANAGER_OF_MACHINE_IDENTITY_OWNER', ManagerOfAccountOwner: 'MANAGER_OF_ACCOUNT_OWNER', ManagerOfMachineAccountOwner: 'MANAGER_OF_MACHINE_ACCOUNT_OWNER', ManagerOfRequester: 'MANAGER_OF_REQUESTER', ManagerOfRequesterOwner: 'MANAGER_OF_REQUESTER_OWNER', ManagerOfOwner: 'MANAGER_OF_OWNER', AccessProfileOwner: 'ACCESS_PROFILE_OWNER', ApplicationOwner: 'APPLICATION_OWNER', EntitlementOwner: 'ENTITLEMENT_OWNER', RoleOwner: 'ROLE_OWNER', SourceOwner: 'SOURCE_OWNER', AccessProfilePrimaryOwner: 'ACCESS_PROFILE_PRIMARY_OWNER', ApplicationPrimaryOwner: 'APPLICATION_PRIMARY_OWNER', EntitlementPrimaryOwner: 'ENTITLEMENT_PRIMARY_OWNER', RolePrimaryOwner: 'ROLE_PRIMARY_OWNER', SourcePrimaryOwner: 'SOURCE_PRIMARY_OWNER' } as const; export type ApprovalConfigEscalationConfigEscalationChainInnerIdentityTypeEnum = typeof ApprovalConfigEscalationConfigEscalationChainInnerIdentityTypeEnum[keyof typeof ApprovalConfigEscalationConfigEscalationChainInnerIdentityTypeEnum]; /** * Configuration for fallback approver. Used if the user cannot be found for whatever reason and escalation config does not exist. * @export * @interface ApprovalConfigFallbackApprover */ export interface ApprovalConfigFallbackApprover { /** * Optional Identity ID of the type of identity defined in the \'type\' field. * @type {string} * @memberof ApprovalConfigFallbackApprover */ 'identityID'?: string; /** * Type of identityID for the fallback approver. * @type {string} * @memberof ApprovalConfigFallbackApprover */ 'type'?: ApprovalConfigFallbackApproverTypeEnum; } export const ApprovalConfigFallbackApproverTypeEnum = { Identity: 'IDENTITY', ManagerOf: 'MANAGER_OF', AccountOwner: 'ACCOUNT_OWNER', MachineAccountOwner: 'MACHINE_ACCOUNT_OWNER', MachineIdentityOwner: 'MACHINE_IDENTITY_OWNER', ManagerOfRequestedTargetOwner: 'MANAGER_OF_REQUESTED_TARGET_OWNER', ManagerOfMachineIdentityOwner: 'MANAGER_OF_MACHINE_IDENTITY_OWNER', ManagerOfAccountOwner: 'MANAGER_OF_ACCOUNT_OWNER', ManagerOfMachineAccountOwner: 'MANAGER_OF_MACHINE_ACCOUNT_OWNER', ManagerOfRequester: 'MANAGER_OF_REQUESTER', ManagerOfRequesterOwner: 'MANAGER_OF_REQUESTER_OWNER', ManagerOfOwner: 'MANAGER_OF_OWNER', AccessProfileOwner: 'ACCESS_PROFILE_OWNER', ApplicationOwner: 'APPLICATION_OWNER', EntitlementOwner: 'ENTITLEMENT_OWNER', RoleOwner: 'ROLE_OWNER', SourceOwner: 'SOURCE_OWNER', RequestedTargetOwner: 'REQUESTED_TARGET_OWNER', AccessProfilePrimaryOwner: 'ACCESS_PROFILE_PRIMARY_OWNER', ApplicationPrimaryOwner: 'APPLICATION_PRIMARY_OWNER', EntitlementPrimaryOwner: 'ENTITLEMENT_PRIMARY_OWNER', RolePrimaryOwner: 'ROLE_PRIMARY_OWNER', SourcePrimaryOwner: 'SOURCE_PRIMARY_OWNER', RequestedTargetPrimaryOwner: 'REQUESTED_TARGET_PRIMARY_OWNER' } as const; export type ApprovalConfigFallbackApproverTypeEnum = typeof ApprovalConfigFallbackApproverTypeEnum[keyof typeof ApprovalConfigFallbackApproverTypeEnum]; /** * Configuration for reminders. * @export * @interface ApprovalConfigReminderConfig */ export interface ApprovalConfigReminderConfig { /** * Indicates if reminders are enabled. * @type {boolean} * @memberof ApprovalConfigReminderConfig */ 'enabled'?: boolean; /** * Number of days until the first reminder. * @type {number} * @memberof ApprovalConfigReminderConfig */ 'daysUntilFirstReminder'?: number; /** * Cron schedule for reminders. * @type {string} * @memberof ApprovalConfigReminderConfig */ 'reminderCronSchedule'?: string; /** * Maximum number of reminders. Max is 20. * @type {number} * @memberof ApprovalConfigReminderConfig */ 'maxReminders'?: number; } /** * * @export * @interface ApprovalConfigSerialChainInner */ export interface ApprovalConfigSerialChainInner { /** * Starting at 1 defines the order in which the identities will get assigned * @type {number} * @memberof ApprovalConfigSerialChainInner */ 'tier'?: number; /** * Optional Identity ID of the type of identity defined in the \'identityType\' field. * @type {string} * @memberof ApprovalConfigSerialChainInner */ 'identityId'?: string; /** * Type of identityId in the serial chain. * @type {string} * @memberof ApprovalConfigSerialChainInner */ 'identityType'?: ApprovalConfigSerialChainInnerIdentityTypeEnum; } export const ApprovalConfigSerialChainInnerIdentityTypeEnum = { Identity: 'IDENTITY', GovernanceGroup: 'GOVERNANCE_GROUP', ManagerOf: 'MANAGER_OF', AccountOwner: 'ACCOUNT_OWNER', MachineAccountOwner: 'MACHINE_ACCOUNT_OWNER', MachineIdentityOwner: 'MACHINE_IDENTITY_OWNER', ManagerOfRequestedTargetOwner: 'MANAGER_OF_REQUESTED_TARGET_OWNER', ManagerOfMachineIdentityOwner: 'MANAGER_OF_MACHINE_IDENTITY_OWNER', ManagerOfAccountOwner: 'MANAGER_OF_ACCOUNT_OWNER', ManagerOfMachineAccountOwner: 'MANAGER_OF_MACHINE_ACCOUNT_OWNER', ManagerOfRequester: 'MANAGER_OF_REQUESTER', ManagerOfRequesterOwner: 'MANAGER_OF_REQUESTER_OWNER', ManagerOfOwner: 'MANAGER_OF_OWNER', AccessProfileOwner: 'ACCESS_PROFILE_OWNER', ApplicationOwner: 'APPLICATION_OWNER', EntitlementOwner: 'ENTITLEMENT_OWNER', RoleOwner: 'ROLE_OWNER', SourceOwner: 'SOURCE_OWNER', RequestedTargetOwner: 'REQUESTED_TARGET_OWNER', AccessProfilePrimaryOwner: 'ACCESS_PROFILE_PRIMARY_OWNER', ApplicationPrimaryOwner: 'APPLICATION_PRIMARY_OWNER', EntitlementPrimaryOwner: 'ENTITLEMENT_PRIMARY_OWNER', RolePrimaryOwner: 'ROLE_PRIMARY_OWNER', SourcePrimaryOwner: 'SOURCE_PRIMARY_OWNER', RequestedTargetPrimaryOwner: 'REQUESTED_TARGET_PRIMARY_OWNER', AccessProfileSecondaryOwnerGroup: 'ACCESS_PROFILE_SECONDARY_OWNER_GROUP', ApplicationSecondaryOwnerGroup: 'APPLICATION_SECONDARY_OWNER_GROUP', EntitlementSecondaryOwnerGroup: 'ENTITLEMENT_SECONDARY_OWNER_GROUP', RoleSecondaryOwnerGroup: 'ROLE_SECONDARY_OWNER_GROUP', SourceSecondaryOwnerGroup: 'SOURCE_SECONDARY_OWNER_GROUP', RequestedTargetSecondaryOwnerGroup: 'REQUESTED_TARGET_SECONDARY_OWNER_GROUP', AccessProfileAllOwnerGroup: 'ACCESS_PROFILE_ALL_OWNER_GROUP', ApplicationAllOwnerGroup: 'APPLICATION_ALL_OWNER_GROUP', EntitlementAllOwnerGroup: 'ENTITLEMENT_ALL_OWNER_GROUP', RoleAllOwnerGroup: 'ROLE_ALL_OWNER_GROUP', SourceAllOwnerGroup: 'SOURCE_ALL_OWNER_GROUP', RequestedTargetAllOwnerGroup: 'REQUESTED_TARGET_ALL_OWNER_GROUP' } as const; export type ApprovalConfigSerialChainInnerIdentityTypeEnum = typeof ApprovalConfigSerialChainInnerIdentityTypeEnum[keyof typeof ApprovalConfigSerialChainInnerIdentityTypeEnum]; /** * TimeoutConfig contains configurations around when the approval request should expire. * @export * @interface ApprovalConfigTimeoutConfig */ export interface ApprovalConfigTimeoutConfig { /** * Indicates if timeout is enabled. * @type {boolean} * @memberof ApprovalConfigTimeoutConfig */ 'enabled'?: boolean; /** * Number of days until approval request times out. Max value is 90. * @type {number} * @memberof ApprovalConfigTimeoutConfig */ 'daysUntilTimeout'?: number; /** * Result of timeout. * @type {string} * @memberof ApprovalConfigTimeoutConfig */ 'timeoutResult'?: ApprovalConfigTimeoutConfigTimeoutResultEnum; } export const ApprovalConfigTimeoutConfigTimeoutResultEnum = { Expired: 'EXPIRED', Approved: 'APPROVED' } as const; export type ApprovalConfigTimeoutConfigTimeoutResultEnum = typeof ApprovalConfigTimeoutConfigTimeoutResultEnum[keyof typeof ApprovalConfigTimeoutConfigTimeoutResultEnum]; /** * The description of what the approval is asking for * @export * @interface ApprovalDescription */ export interface ApprovalDescription { /** * The description of what the approval is asking for * @type {string} * @memberof ApprovalDescription */ 'value'?: string; /** * What locale the description of the approval is using * @type {string} * @memberof ApprovalDescription */ 'locale'?: string; } /** * Approval Identity Object * @export * @interface ApprovalIdentity */ export interface ApprovalIdentity { /** * Email address. * @type {string} * @memberof ApprovalIdentity */ 'email'?: string; /** * Identity ID of the type of identity defined in the \'type\' field. * @type {string} * @memberof ApprovalIdentity */ 'identityID'?: string; /** * List of members of a governance group. Will be omitted if the identity is not a governance group. * @type {Array} * @memberof ApprovalIdentity */ 'members'?: Array; /** * Name of the identity. * @type {string} * @memberof ApprovalIdentity */ 'name'?: string; /** * List of owned items. For example, will show the items in which a ROLE_OWNER owns. Omitted if not an owner of anything. * @type {Array} * @memberof ApprovalIdentity */ 'ownerOf'?: Array; /** * The serial step of the identity in the approval. For example serialOrder 1 is the first identity to action in an approval request chain. Parallel approvals are set to 0. * @type {number} * @memberof ApprovalIdentity */ 'serialOrder'?: number; /** * Type of identityID. * @type {string} * @memberof ApprovalIdentity */ 'type'?: ApprovalIdentityTypeEnum; } export const ApprovalIdentityTypeEnum = { Identity: 'IDENTITY', GovernanceGroup: 'GOVERNANCE_GROUP', ManagerOf: 'MANAGER_OF', AccountOwner: 'ACCOUNT_OWNER', MachineAccountOwner: 'MACHINE_ACCOUNT_OWNER', MachineIdentityOwner: 'MACHINE_IDENTITY_OWNER', ManagerOfRequestedTargetOwner: 'MANAGER_OF_REQUESTED_TARGET_OWNER', ManagerOfMachineIdentityOwner: 'MANAGER_OF_MACHINE_IDENTITY_OWNER', ManagerOfAccountOwner: 'MANAGER_OF_ACCOUNT_OWNER', ManagerOfMachineAccountOwner: 'MANAGER_OF_MACHINE_ACCOUNT_OWNER', ManagerOfRequester: 'MANAGER_OF_REQUESTER', ManagerOfRequesterOwner: 'MANAGER_OF_REQUESTER_OWNER', ManagerOfOwner: 'MANAGER_OF_OWNER', AccessProfileOwner: 'ACCESS_PROFILE_OWNER', ApplicationOwner: 'APPLICATION_OWNER', EntitlementOwner: 'ENTITLEMENT_OWNER', RoleOwner: 'ROLE_OWNER', SourceOwner: 'SOURCE_OWNER', RequestedTargetOwner: 'REQUESTED_TARGET_OWNER', AccessProfilePrimaryOwner: 'ACCESS_PROFILE_PRIMARY_OWNER', ApplicationPrimaryOwner: 'APPLICATION_PRIMARY_OWNER', EntitlementPrimaryOwner: 'ENTITLEMENT_PRIMARY_OWNER', RolePrimaryOwner: 'ROLE_PRIMARY_OWNER', SourcePrimaryOwner: 'SOURCE_PRIMARY_OWNER', RequestedTargetPrimaryOwner: 'REQUESTED_TARGET_PRIMARY_OWNER', AccessProfileSecondaryOwnerGroup: 'ACCESS_PROFILE_SECONDARY_OWNER_GROUP', ApplicationSecondaryOwnerGroup: 'APPLICATION_SECONDARY_OWNER_GROUP', EntitlementSecondaryOwnerGroup: 'ENTITLEMENT_SECONDARY_OWNER_GROUP', RoleSecondaryOwnerGroup: 'ROLE_SECONDARY_OWNER_GROUP', SourceSecondaryOwnerGroup: 'SOURCE_SECONDARY_OWNER_GROUP', RequestedTargetSecondaryOwnerGroup: 'REQUESTED_TARGET_SECONDARY_OWNER_GROUP', AccessProfileAllOwnerGroup: 'ACCESS_PROFILE_ALL_OWNER_GROUP', ApplicationAllOwnerGroup: 'APPLICATION_ALL_OWNER_GROUP', EntitlementAllOwnerGroup: 'ENTITLEMENT_ALL_OWNER_GROUP', RoleAllOwnerGroup: 'ROLE_ALL_OWNER_GROUP', SourceAllOwnerGroup: 'SOURCE_ALL_OWNER_GROUP', RequestedTargetAllOwnerGroup: 'REQUESTED_TARGET_ALL_OWNER_GROUP' } as const; export type ApprovalIdentityTypeEnum = typeof ApprovalIdentityTypeEnum[keyof typeof ApprovalIdentityTypeEnum]; /** * * @export * @interface ApprovalIdentityMembersInner */ export interface ApprovalIdentityMembersInner { /** * Email of the member. * @type {string} * @memberof ApprovalIdentityMembersInner */ 'email'?: string; /** * ID of the member. * @type {string} * @memberof ApprovalIdentityMembersInner */ 'id'?: string; /** * Name of the member. * @type {string} * @memberof ApprovalIdentityMembersInner */ 'name'?: string; /** * Type of the member. * @type {string} * @memberof ApprovalIdentityMembersInner */ 'type'?: string; } /** * * @export * @interface ApprovalIdentityOwnerOfInner */ export interface ApprovalIdentityOwnerOfInner { /** * ID of the object that is owned. * @type {string} * @memberof ApprovalIdentityOwnerOfInner */ 'id'?: string; /** * Name of the object that is owned. * @type {string} * @memberof ApprovalIdentityOwnerOfInner */ 'name'?: string; /** * Type of the object that is owned. * @type {string} * @memberof ApprovalIdentityOwnerOfInner */ 'type'?: string; } /** * Identity Record Object * @export * @interface ApprovalIdentityRecord */ export interface ApprovalIdentityRecord { /** * Identity ID. * @type {string} * @memberof ApprovalIdentityRecord */ 'identityID'?: string; /** * Type of identity. * @type {string} * @memberof ApprovalIdentityRecord */ 'type'?: ApprovalIdentityRecordTypeEnum; /** * Name of the identity. * @type {string} * @memberof ApprovalIdentityRecord */ 'name'?: string; /** * List of references representing actions taken by the identity. * @type {Array} * @memberof ApprovalIdentityRecord */ 'actionedAs'?: Array; /** * List of references representing members of the identity. * @type {Array} * @memberof ApprovalIdentityRecord */ 'members'?: Array; /** * Date when the decision was made. * @type {string} * @memberof ApprovalIdentityRecord */ 'decisionDate'?: string; /** * Email associated with the identity. * @type {string} * @memberof ApprovalIdentityRecord */ 'email'?: string; } export const ApprovalIdentityRecordTypeEnum = { Identity: 'IDENTITY' } as const; export type ApprovalIdentityRecordTypeEnum = typeof ApprovalIdentityRecordTypeEnum[keyof typeof ApprovalIdentityRecordTypeEnum]; /** * Approval Name Object * @export * @interface ApprovalName */ export interface ApprovalName { /** * Name of the approval * @type {string} * @memberof ApprovalName */ 'value'?: string; /** * What locale the name of the approval is using * @type {string} * @memberof ApprovalName */ 'locale'?: string; } /** * Request body for reassigning an approval request to another identity. This results in that identity being added as an authorized approver. * @export * @interface ApprovalReassignRequest */ export interface ApprovalReassignRequest { /** * Comment associated with the reassign request. * @type {string} * @memberof ApprovalReassignRequest */ 'comment'?: string; /** * Identity from which the approval is being reassigned. If left blank, and the approval is currently assigned to the user calling this endpoint, it will use the calling user\'s identity. If left blank, and the approval is not currently assigned to the user calling this endpoint, you need to be an admin, which would add the reassignTo as a new approver. * @type {string} * @memberof ApprovalReassignRequest */ 'reassignFrom'?: string; /** * Identity to which the approval is being reassigned. * @type {string} * @memberof ApprovalReassignRequest */ 'reassignTo'?: string; } /** * ReassignmentHistoryRecord holds a history record of reassignment and escalation actions for an approval request * @export * @interface ApprovalReassignmentHistory */ export interface ApprovalReassignmentHistory { /** * Unique identifier for the comment associated with the reassignment. * @type {string} * @memberof ApprovalReassignmentHistory */ 'commentID'?: string; /** * * @type {ApprovalIdentity} * @memberof ApprovalReassignmentHistory */ 'reassignedFrom'?: ApprovalIdentity; /** * * @type {ApprovalIdentity} * @memberof ApprovalReassignmentHistory */ 'reassignedTo'?: ApprovalIdentity; /** * * @type {ApprovalIdentity} * @memberof ApprovalReassignmentHistory */ 'reassigner'?: ApprovalIdentity; /** * Date and time when the reassignment occurred. * @type {string} * @memberof ApprovalReassignmentHistory */ 'reassignmentDate'?: string; /** * Type of reassignment, such as escalation or manual reassignment. * @type {string} * @memberof ApprovalReassignmentHistory */ 'reassignmentType'?: ApprovalReassignmentHistoryReassignmentTypeEnum; } export const ApprovalReassignmentHistoryReassignmentTypeEnum = { Escalation: 'ESCALATION', ManualReassignment: 'MANUAL_REASSIGNMENT', AutoReassignment: 'AUTO_REASSIGNMENT' } as const; export type ApprovalReassignmentHistoryReassignmentTypeEnum = typeof ApprovalReassignmentHistoryReassignmentTypeEnum[keyof typeof ApprovalReassignmentHistoryReassignmentTypeEnum]; /** * Reference objects related to the approval * @export * @interface ApprovalReference */ export interface ApprovalReference { /** * Id of the reference object * @type {string} * @memberof ApprovalReference */ 'id'?: string; /** * What reference object does this ID correspond to * @type {string} * @memberof ApprovalReference */ 'type'?: string; /** * Name of the reference object * @type {string} * @memberof ApprovalReference */ 'name'?: string; /** * Email associated with the reference object * @type {string} * @memberof ApprovalReference */ 'email'?: string; /** * The serial step of the identity in the approval. For example serialOrder 1 is the first identity to action in an approval request chain. Parallel approvals are set to 0. * @type {number} * @memberof ApprovalReference */ 'serialOrder'?: number; } /** * Request body for rejecting an approval request. * @export * @interface ApprovalRejectRequest */ export interface ApprovalRejectRequest { /** * Comment associated with the reject request. * @type {string} * @memberof ApprovalRejectRequest */ 'comment'?: string; } /** * Represents a requested target in an approval process, including details such as ID, name, reauthentication requirements, and removal date. * @export * @interface ApprovalRequestedTarget */ export interface ApprovalRequestedTarget { /** * Signature required for forced authentication. * @type {string} * @memberof ApprovalRequestedTarget */ 'forcedAuthSignature'?: string; /** * ID of the requested target. * @type {string} * @memberof ApprovalRequestedTarget */ 'id'?: string; /** * Name of the requested target. * @type {string} * @memberof ApprovalRequestedTarget */ 'name'?: string; /** * Indicates if reauthentication is required. * @type {boolean} * @memberof ApprovalRequestedTarget */ 'reauthRequired'?: boolean; /** * Date when the target will be removed. * @type {string} * @memberof ApprovalRequestedTarget */ 'removalDate'?: string; /** * Type of the request. * @type {string} * @memberof ApprovalRequestedTarget */ 'requestType'?: string; /** * Type of the target. * @type {string} * @memberof ApprovalRequestedTarget */ 'targetType'?: string; } /** * BulkApproveRequestDTO is the input struct that represents the request body required to facilitate a bulk approval action for a set of generic approval requests. * @export * @interface BulkApproveRequestDTO */ export interface BulkApproveRequestDTO { /** * Array of Approval IDs to be bulk approved * @type {Array} * @memberof BulkApproveRequestDTO */ 'approvalIds'?: Array; /** * Optional comment to include with the bulk approval request * @type {string} * @memberof BulkApproveRequestDTO */ 'comment'?: string; /** * Additional attributes to include with the bulk approval request * @type {{ [key: string]: any; }} * @memberof BulkApproveRequestDTO */ 'additionalAttributes'?: { [key: string]: any; }; } /** * BulkCancelRequestDTO is the input struct that represents the request body required to facilitate a bulk cancellation action for a set of generic approval requests. * @export * @interface BulkCancelRequestDTO */ export interface BulkCancelRequestDTO { /** * Array of Approval IDs to be bulk cancelled * @type {Array} * @memberof BulkCancelRequestDTO */ 'approvalIds'?: Array; /** * Optional comment to include with the bulk cancellation request * @type {string} * @memberof BulkCancelRequestDTO */ 'comment'?: string; } /** * BulkReassignRequestDTO is the input struct that represents the request body required to facilitate a bulk reassignment action for a set of generic approval requests. * @export * @interface BulkReassignRequestDTO */ export interface BulkReassignRequestDTO { /** * Array of Approval IDs to be bulk reassigned * @type {Array} * @memberof BulkReassignRequestDTO */ 'approvalIds'?: Array; /** * Optional comment to include with the bulk reassignment request * @type {string} * @memberof BulkReassignRequestDTO */ 'comment'?: string; /** * Identity ID from which the approval requests are being reassigned * @type {string} * @memberof BulkReassignRequestDTO */ 'reassignFrom'?: string; /** * ReassignTo signifies the Identity ID that the approval request is being reassigned to * @type {string} * @memberof BulkReassignRequestDTO */ 'reassignTo'?: string; } /** * BulkRejectRequestDTO is the input struct that represents the request body required to facilitate a bulk reject action for a set of generic approval requests. * @export * @interface BulkRejectRequestDTO */ export interface BulkRejectRequestDTO { /** * Array of Approval IDs to be bulk rejected * @type {Array} * @memberof BulkRejectRequestDTO */ 'approvalIds'?: Array; /** * Optional comment to include with the bulk reject request * @type {string} * @memberof BulkRejectRequestDTO */ 'comment'?: string; } /** * * @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 GetApprovalsV1401Response */ export interface GetApprovalsV1401Response { /** * A message describing the error * @type {any} * @memberof GetApprovalsV1401Response */ 'error'?: any; } /** * * @export * @interface GetApprovalsV1429Response */ export interface GetApprovalsV1429Response { /** * A message describing the error * @type {any} * @memberof GetApprovalsV1429Response */ '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]; /** * ApprovalsApi - axios parameter creator * @export */ export const ApprovalsApiAxiosParamCreator = function (configuration?: Configuration) { return { /** * Bulk Approves specified approval requests on behalf of the caller * @summary Post Bulk Approve Approvals * @param {BulkApproveRequestDTO} bulkApproveRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalInBulkV1: async (bulkApproveRequestDTO: BulkApproveRequestDTO, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'bulkApproveRequestDTO' is not null or undefined assertParamExists('approveApprovalInBulkV1', 'bulkApproveRequestDTO', bulkApproveRequestDTO) const localVarPath = `/generic-approvals/v1/bulk-approve`; // 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(bulkApproveRequestDTO, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Approves a specified approval request on behalf of the caller. The approval request must be in a state that allows it to be approved. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user. * @summary Post Approvals Approve * @param {string} id Approval ID that correlates to an existing approval request that a user wants to approve. * @param {ApprovalApproveRequest} [approvalApproveRequest] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalV1: async (id: string, approvalApproveRequest?: ApprovalApproveRequest, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('approveApprovalV1', 'id', id) const localVarPath = `/generic-approvals/v1/{id}/approve` .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(approvalApproveRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Cancels a specified approval requests on behalf of the caller. Note: This endpoint does not support access request IDs. To cancel access request approvals, please use the following: /access-requests/cancel * @summary Post Approval Cancel * @param {string} id ID of the approval request to cancel. * @param {ApprovalCancelRequest} [approvalCancelRequest] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ cancelApprovalByIdV1: async (id: string, approvalCancelRequest?: ApprovalCancelRequest, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('cancelApprovalByIdV1', 'id', id) const localVarPath = `/generic-approvals/v1/{id}/cancel` .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(approvalCancelRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Bulk cancels specified approval requests on behalf of the caller. Note: To bulk cancel access request approvals, please use the following: /access-requests/bulk-cancel * @summary Post Bulk Cancel Approvals * @param {BulkCancelRequestDTO} bulkCancelRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ cancelApprovalV1: async (bulkCancelRequestDTO: BulkCancelRequestDTO, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'bulkCancelRequestDTO' is not null or undefined assertParamExists('cancelApprovalV1', 'bulkCancelRequestDTO', bulkCancelRequestDTO) const localVarPath = `/generic-approvals/v1/bulk-cancel`; // 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(bulkCancelRequestDTO, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Deletes an approval configuration. Configurations at the APPROVAL_REQUEST scope cannot be deleted. * @summary Delete Approval Configuration * @param {string} id The ID defined by the scope field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {DeleteApprovalConfigRequestV1ScopeEnum} scope The scope of the field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ deleteApprovalConfigRequestV1: async (id: string, scope: DeleteApprovalConfigRequestV1ScopeEnum, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('deleteApprovalConfigRequestV1', 'id', id) // verify required parameter 'scope' is not null or undefined assertParamExists('deleteApprovalConfigRequestV1', 'scope', scope) const localVarPath = `/generic-approvals/v1/config/{id}/{scope}` .replace(`{${"id"}}`, encodeURIComponent(String(id))) .replace(`{${"scope"}}`, encodeURIComponent(String(scope))); // 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: 'DELETE', ...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, }; }, /** * Fetches an approval request by it\'s approval ID. For lookups by access request ID please use the following: /generic-approvals?filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\" * @summary Get an approval * @param {string} id ID of the approval that is to be returned * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getApprovalV1: async (id: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('getApprovalV1', 'id', id) const localVarPath = `/generic-approvals/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, }; }, /** * Retrieves a singular approval configuration that matches the given ID * @summary Get Approval Config * @param {string} id The id of the object the config applies to, for example one of the following: [(approvalID), (roleID), (entitlementID), (accessProfileID), \"ENTITLEMENT_DESCRIPTIONS\", \"ACCESS_REQUEST_APPROVAL\", \"ACCOUNT_CREATE_APPROVAL_REQUEST\", \"ACCOUNT_DELETE_APPROVAL_REQUEST\", \"MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST\", \"MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST\", (tenantID)] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getApprovalsConfigV1: async (id: string, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('getApprovalsConfigV1', 'id', id) const localVarPath = `/generic-approvals/v1/config/{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, }; }, /** * Gets a list of approvals. One of the following query parameters should be present: \'mine\', \'approverId\', \'requesterId\', \'requesteeId\'. The absence of all query parameters for non admins will default to mine=true (which is the equivalent of \'approverId=[your_identity_id]\') while admins will default to mine=false (which will show all approvals in the org). For lookups by access request ID please use the following: \'/generic-approvals?mine=false&filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\"\' * @summary Get approvals * @param {boolean} [mine] Determines whether to return the list of approvals assigned to the current caller or all approvals in the org. Defaults to false if admin, true otherwise (which is the equivalent of \'approverId=[your_identity_id]\'). * @param {string} [requesterId] Returns the list of approvals for a given requester ID. Must match the calling user\'s identity ID unless they are an admin. * @param {string} [requesteeId] Returns the list of approvals for a given requesteeId ID. Must match the calling user\'s identity ID unless they are an admin. * @param {string} [approverId] Returns the list of approvals for a given approverId ID. Must match the calling user\'s identity ID unless they are an admin. * @param {boolean} [count] Adds X-Total-Count to the header to give the amount of total approvals returned from the query. * @param {boolean} [countOnly] Adds X-Total-Count to the header to give the amount of total approvals returned from the query. Only returns the count and no approval objects. * @param {boolean} [includeComments] If set to true in the query, the approval requests returned will include comments. * @param {boolean} [includeApprovers] If set to true in the query, the approval requests returned will include approvers. * @param {boolean} [includeReassignmentHistory] If set to true in the query, the approval requests returned will include reassignment history. * @param {boolean} [includeBatchInfo] If set to true in the query, the approval requests returned will include batch information. * @param {string} [filters] Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **status**: *eq, ne, in, co, sw* **name**: *eq, ne, in, co, sw* **priority**: *eq, ne, in, co, sw* **type**: *eq, ne, in, co, sw* **medium**: *eq, ne, in, co, sw* **description**: *eq, ne, in, co, sw* **batchId**: *eq, ne, in, co, sw* **createdDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **dueDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **completedDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **search**: *eq, ne, in, co, sw* **referenceId**: *eq, ne, in, co, sw* **referenceType**: *eq, ne, in, co, sw* **referenceName**: *eq, ne, in, co, sw* **requestedTargetId**: *eq, ne, in, co, sw* **requestedTargetType**: *eq, ne, in, co, sw* **requestedTargetName**: *eq, ne, in, co, sw* **requestedTargetRequestType**: *eq, ne, in, co, sw* **modifiedDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **decisionDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **approvalId**: *eq, ne, in, co, sw* **requesterId**: *eq, ne, in, co, sw* **requesteeId**: *eq, ne, in, co, sw* **approverId**: *eq, ne, in, co, sw* * @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 {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getApprovalsV1: async (mine?: boolean, requesterId?: string, requesteeId?: string, approverId?: string, count?: boolean, countOnly?: boolean, includeComments?: boolean, includeApprovers?: boolean, includeReassignmentHistory?: boolean, includeBatchInfo?: boolean, filters?: string, limit?: number, offset?: number, axiosOptions: RawAxiosRequestConfig = {}): Promise => { const localVarPath = `/generic-approvals/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 (mine !== undefined) { localVarQueryParameter['mine'] = mine; } if (requesterId !== undefined) { localVarQueryParameter['requesterId'] = requesterId; } if (requesteeId !== undefined) { localVarQueryParameter['requesteeId'] = requesteeId; } if (approverId !== undefined) { localVarQueryParameter['approverId'] = approverId; } if (count !== undefined) { localVarQueryParameter['count'] = count; } if (countOnly !== undefined) { localVarQueryParameter['count-only'] = countOnly; } if (includeComments !== undefined) { localVarQueryParameter['include-comments'] = includeComments; } if (includeApprovers !== undefined) { localVarQueryParameter['include-approvers'] = includeApprovers; } if (includeReassignmentHistory !== undefined) { localVarQueryParameter['include-reassignment-history'] = includeReassignmentHistory; } if (includeBatchInfo !== undefined) { localVarQueryParameter['include-batch-info'] = includeBatchInfo; } if (filters !== undefined) { localVarQueryParameter['filters'] = filters; } if (limit !== undefined) { localVarQueryParameter['limit'] = limit; } if (offset !== undefined) { localVarQueryParameter['offset'] = offset; } setSearchParams(localVarUrlObj, localVarQueryParameter); let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {}; localVarRequestOptions.headers = {...localVarHeaderParameter, ...headersFromBaseOptions, ...axiosOptions.headers}; return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Bulk reassigns specified approval requests on behalf of the caller * @summary Post Bulk Reassign Approvals * @param {BulkReassignRequestDTO} bulkReassignRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ moveApprovalV1: async (bulkReassignRequestDTO: BulkReassignRequestDTO, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'bulkReassignRequestDTO' is not null or undefined assertParamExists('moveApprovalV1', 'bulkReassignRequestDTO', bulkReassignRequestDTO) const localVarPath = `/generic-approvals/v1/bulk-reassign`; // 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(bulkReassignRequestDTO, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Upserts a singular approval configuration that matches the given configID and configScope. For example to update the approval configurations for all Access Request Approvals please use: \'/generic-approvals/config/ACCESS_REQUEST_APPROVAL/APPROVAL_TYPE\' * @summary Put Approval Config * @param {string} id The ID defined by the scope field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {PutApprovalsConfigV1ScopeEnum} scope The scope of the field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {ApprovalConfig} approvalConfig * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ putApprovalsConfigV1: async (id: string, scope: PutApprovalsConfigV1ScopeEnum, approvalConfig: ApprovalConfig, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('putApprovalsConfigV1', 'id', id) // verify required parameter 'scope' is not null or undefined assertParamExists('putApprovalsConfigV1', 'scope', scope) // verify required parameter 'approvalConfig' is not null or undefined assertParamExists('putApprovalsConfigV1', 'approvalConfig', approvalConfig) const localVarPath = `/generic-approvals/v1/config/{id}/{scope}` .replace(`{${"id"}}`, encodeURIComponent(String(id))) .replace(`{${"scope"}}`, encodeURIComponent(String(scope))); // 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: 'PUT', ...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(approvalConfig, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Bulk reject specified approval requests on behalf of the caller * @summary Post Bulk Reject Approvals * @param {BulkRejectRequestDTO} bulkRejectRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalInBulkV1: async (bulkRejectRequestDTO: BulkRejectRequestDTO, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'bulkRejectRequestDTO' is not null or undefined assertParamExists('rejectApprovalInBulkV1', 'bulkRejectRequestDTO', bulkRejectRequestDTO) const localVarPath = `/generic-approvals/v1/bulk-reject`; // 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(bulkRejectRequestDTO, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Rejects a specified approval request on behalf of the caller. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user and approved. * @summary Post Approvals Reject * @param {string} id Approval ID that correlates to an existing approval request that a user wants to reject. * @param {ApprovalRejectRequest} [approvalRejectRequest] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalV1: async (id: string, approvalRejectRequest?: ApprovalRejectRequest, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('rejectApprovalV1', 'id', id) const localVarPath = `/generic-approvals/v1/{id}/reject` .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(approvalRejectRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Allows for the edit/addition/removal of the key/value pair additional attributes map for an existing approval request. This endpoint does not support access request IDs. * @summary Post Approvals Attributes * @param {string} id Approval ID that correlates to an existing approval request that a user wants to change the attributes of. * @param {ApprovalAttributesRequest} approvalAttributesRequest * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ updateApprovalsAttributesV1: async (id: string, approvalAttributesRequest: ApprovalAttributesRequest, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('updateApprovalsAttributesV1', 'id', id) // verify required parameter 'approvalAttributesRequest' is not null or undefined assertParamExists('updateApprovalsAttributesV1', 'approvalAttributesRequest', approvalAttributesRequest) const localVarPath = `/generic-approvals/v1/{id}/attributes` .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(approvalAttributesRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Adds comments to a specified approval request. This endpoint does not support access request IDs. * @summary Post Approvals Comments * @param {string} id Approval ID that correlates to an existing approval request that a user wants to add a comment to. * @param {ApprovalCommentsRequest} approvalCommentsRequest * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ updateApprovalsCommentsV1: async (id: string, approvalCommentsRequest: ApprovalCommentsRequest, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('updateApprovalsCommentsV1', 'id', id) // verify required parameter 'approvalCommentsRequest' is not null or undefined assertParamExists('updateApprovalsCommentsV1', 'approvalCommentsRequest', approvalCommentsRequest) const localVarPath = `/generic-approvals/v1/{id}/comments` .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(approvalCommentsRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, /** * Reassigns an approval request to another identity resulting in that identity being added as an authorized approver. This endpoint does not support access request IDs. * @summary Post Approvals Reassign * @param {string} id Approval ID that correlates to an existing approval request that a user wants to reassign. * @param {ApprovalReassignRequest} approvalReassignRequest * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ updateApprovalsReassignV1: async (id: string, approvalReassignRequest: ApprovalReassignRequest, axiosOptions: RawAxiosRequestConfig = {}): Promise => { // verify required parameter 'id' is not null or undefined assertParamExists('updateApprovalsReassignV1', 'id', id) // verify required parameter 'approvalReassignRequest' is not null or undefined assertParamExists('updateApprovalsReassignV1', 'approvalReassignRequest', approvalReassignRequest) const localVarPath = `/generic-approvals/v1/{id}/reassign` .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(approvalReassignRequest, localVarRequestOptions, configuration) return { url: toPathString(localVarUrlObj), axiosOptions: localVarRequestOptions, }; }, } }; /** * ApprovalsApi - functional programming interface * @export */ export const ApprovalsApiFp = function(configuration?: Configuration) { const localVarAxiosParamCreator = ApprovalsApiAxiosParamCreator(configuration) return { /** * Bulk Approves specified approval requests on behalf of the caller * @summary Post Bulk Approve Approvals * @param {BulkApproveRequestDTO} bulkApproveRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async approveApprovalInBulkV1(bulkApproveRequestDTO: BulkApproveRequestDTO, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.approveApprovalInBulkV1(bulkApproveRequestDTO, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.approveApprovalInBulkV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Approves a specified approval request on behalf of the caller. The approval request must be in a state that allows it to be approved. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user. * @summary Post Approvals Approve * @param {string} id Approval ID that correlates to an existing approval request that a user wants to approve. * @param {ApprovalApproveRequest} [approvalApproveRequest] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async approveApprovalV1(id: string, approvalApproveRequest?: ApprovalApproveRequest, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.approveApprovalV1(id, approvalApproveRequest, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.approveApprovalV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Cancels a specified approval requests on behalf of the caller. Note: This endpoint does not support access request IDs. To cancel access request approvals, please use the following: /access-requests/cancel * @summary Post Approval Cancel * @param {string} id ID of the approval request to cancel. * @param {ApprovalCancelRequest} [approvalCancelRequest] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async cancelApprovalByIdV1(id: string, approvalCancelRequest?: ApprovalCancelRequest, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.cancelApprovalByIdV1(id, approvalCancelRequest, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.cancelApprovalByIdV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Bulk cancels specified approval requests on behalf of the caller. Note: To bulk cancel access request approvals, please use the following: /access-requests/bulk-cancel * @summary Post Bulk Cancel Approvals * @param {BulkCancelRequestDTO} bulkCancelRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async cancelApprovalV1(bulkCancelRequestDTO: BulkCancelRequestDTO, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.cancelApprovalV1(bulkCancelRequestDTO, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.cancelApprovalV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Deletes an approval configuration. Configurations at the APPROVAL_REQUEST scope cannot be deleted. * @summary Delete Approval Configuration * @param {string} id The ID defined by the scope field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {DeleteApprovalConfigRequestV1ScopeEnum} scope The scope of the field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async deleteApprovalConfigRequestV1(id: string, scope: DeleteApprovalConfigRequestV1ScopeEnum, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.deleteApprovalConfigRequestV1(id, scope, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.deleteApprovalConfigRequestV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Fetches an approval request by it\'s approval ID. For lookups by access request ID please use the following: /generic-approvals?filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\" * @summary Get an approval * @param {string} id ID of the approval that is to be returned * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getApprovalV1(id: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getApprovalV1(id, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.getApprovalV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Retrieves a singular approval configuration that matches the given ID * @summary Get Approval Config * @param {string} id The id of the object the config applies to, for example one of the following: [(approvalID), (roleID), (entitlementID), (accessProfileID), \"ENTITLEMENT_DESCRIPTIONS\", \"ACCESS_REQUEST_APPROVAL\", \"ACCOUNT_CREATE_APPROVAL_REQUEST\", \"ACCOUNT_DELETE_APPROVAL_REQUEST\", \"MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST\", \"MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST\", (tenantID)] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getApprovalsConfigV1(id: string, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.getApprovalsConfigV1(id, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.getApprovalsConfigV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Gets a list of approvals. One of the following query parameters should be present: \'mine\', \'approverId\', \'requesterId\', \'requesteeId\'. The absence of all query parameters for non admins will default to mine=true (which is the equivalent of \'approverId=[your_identity_id]\') while admins will default to mine=false (which will show all approvals in the org). For lookups by access request ID please use the following: \'/generic-approvals?mine=false&filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\"\' * @summary Get approvals * @param {boolean} [mine] Determines whether to return the list of approvals assigned to the current caller or all approvals in the org. Defaults to false if admin, true otherwise (which is the equivalent of \'approverId=[your_identity_id]\'). * @param {string} [requesterId] Returns the list of approvals for a given requester ID. Must match the calling user\'s identity ID unless they are an admin. * @param {string} [requesteeId] Returns the list of approvals for a given requesteeId ID. Must match the calling user\'s identity ID unless they are an admin. * @param {string} [approverId] Returns the list of approvals for a given approverId ID. Must match the calling user\'s identity ID unless they are an admin. * @param {boolean} [count] Adds X-Total-Count to the header to give the amount of total approvals returned from the query. * @param {boolean} [countOnly] Adds X-Total-Count to the header to give the amount of total approvals returned from the query. Only returns the count and no approval objects. * @param {boolean} [includeComments] If set to true in the query, the approval requests returned will include comments. * @param {boolean} [includeApprovers] If set to true in the query, the approval requests returned will include approvers. * @param {boolean} [includeReassignmentHistory] If set to true in the query, the approval requests returned will include reassignment history. * @param {boolean} [includeBatchInfo] If set to true in the query, the approval requests returned will include batch information. * @param {string} [filters] Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **status**: *eq, ne, in, co, sw* **name**: *eq, ne, in, co, sw* **priority**: *eq, ne, in, co, sw* **type**: *eq, ne, in, co, sw* **medium**: *eq, ne, in, co, sw* **description**: *eq, ne, in, co, sw* **batchId**: *eq, ne, in, co, sw* **createdDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **dueDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **completedDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **search**: *eq, ne, in, co, sw* **referenceId**: *eq, ne, in, co, sw* **referenceType**: *eq, ne, in, co, sw* **referenceName**: *eq, ne, in, co, sw* **requestedTargetId**: *eq, ne, in, co, sw* **requestedTargetType**: *eq, ne, in, co, sw* **requestedTargetName**: *eq, ne, in, co, sw* **requestedTargetRequestType**: *eq, ne, in, co, sw* **modifiedDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **decisionDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **approvalId**: *eq, ne, in, co, sw* **requesterId**: *eq, ne, in, co, sw* **requesteeId**: *eq, ne, in, co, sw* **approverId**: *eq, ne, in, co, sw* * @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 {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async getApprovalsV1(mine?: boolean, requesterId?: string, requesteeId?: string, approverId?: string, count?: boolean, countOnly?: boolean, includeComments?: boolean, includeApprovers?: boolean, includeReassignmentHistory?: boolean, includeBatchInfo?: boolean, filters?: string, limit?: number, offset?: number, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise>> { const localVarAxiosArgs = await localVarAxiosParamCreator.getApprovalsV1(mine, requesterId, requesteeId, approverId, count, countOnly, includeComments, includeApprovers, includeReassignmentHistory, includeBatchInfo, filters, limit, offset, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.getApprovalsV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Bulk reassigns specified approval requests on behalf of the caller * @summary Post Bulk Reassign Approvals * @param {BulkReassignRequestDTO} bulkReassignRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async moveApprovalV1(bulkReassignRequestDTO: BulkReassignRequestDTO, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.moveApprovalV1(bulkReassignRequestDTO, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.moveApprovalV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Upserts a singular approval configuration that matches the given configID and configScope. For example to update the approval configurations for all Access Request Approvals please use: \'/generic-approvals/config/ACCESS_REQUEST_APPROVAL/APPROVAL_TYPE\' * @summary Put Approval Config * @param {string} id The ID defined by the scope field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {PutApprovalsConfigV1ScopeEnum} scope The scope of the field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @param {ApprovalConfig} approvalConfig * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async putApprovalsConfigV1(id: string, scope: PutApprovalsConfigV1ScopeEnum, approvalConfig: ApprovalConfig, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.putApprovalsConfigV1(id, scope, approvalConfig, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.putApprovalsConfigV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Bulk reject specified approval requests on behalf of the caller * @summary Post Bulk Reject Approvals * @param {BulkRejectRequestDTO} bulkRejectRequestDTO * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async rejectApprovalInBulkV1(bulkRejectRequestDTO: BulkRejectRequestDTO, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.rejectApprovalInBulkV1(bulkRejectRequestDTO, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.rejectApprovalInBulkV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Rejects a specified approval request on behalf of the caller. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user and approved. * @summary Post Approvals Reject * @param {string} id Approval ID that correlates to an existing approval request that a user wants to reject. * @param {ApprovalRejectRequest} [approvalRejectRequest] * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async rejectApprovalV1(id: string, approvalRejectRequest?: ApprovalRejectRequest, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.rejectApprovalV1(id, approvalRejectRequest, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.rejectApprovalV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Allows for the edit/addition/removal of the key/value pair additional attributes map for an existing approval request. This endpoint does not support access request IDs. * @summary Post Approvals Attributes * @param {string} id Approval ID that correlates to an existing approval request that a user wants to change the attributes of. * @param {ApprovalAttributesRequest} approvalAttributesRequest * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async updateApprovalsAttributesV1(id: string, approvalAttributesRequest: ApprovalAttributesRequest, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.updateApprovalsAttributesV1(id, approvalAttributesRequest, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.updateApprovalsAttributesV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Adds comments to a specified approval request. This endpoint does not support access request IDs. * @summary Post Approvals Comments * @param {string} id Approval ID that correlates to an existing approval request that a user wants to add a comment to. * @param {ApprovalCommentsRequest} approvalCommentsRequest * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async updateApprovalsCommentsV1(id: string, approvalCommentsRequest: ApprovalCommentsRequest, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.updateApprovalsCommentsV1(id, approvalCommentsRequest, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.updateApprovalsCommentsV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, /** * Reassigns an approval request to another identity resulting in that identity being added as an authorized approver. This endpoint does not support access request IDs. * @summary Post Approvals Reassign * @param {string} id Approval ID that correlates to an existing approval request that a user wants to reassign. * @param {ApprovalReassignRequest} approvalReassignRequest * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ async updateApprovalsReassignV1(id: string, approvalReassignRequest: ApprovalReassignRequest, axiosOptions?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise> { const localVarAxiosArgs = await localVarAxiosParamCreator.updateApprovalsReassignV1(id, approvalReassignRequest, axiosOptions); const localVarOperationServerIndex = configuration?.serverIndex ?? 0; const localVarOperationServerBasePath = operationServerMap['ApprovalsApi.updateApprovalsReassignV1']?.[localVarOperationServerIndex]?.url; return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath); }, } }; /** * ApprovalsApi - factory interface * @export */ export const ApprovalsApiFactory = function (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) { const localVarFp = ApprovalsApiFp(configuration) return { /** * Bulk Approves specified approval requests on behalf of the caller * @summary Post Bulk Approve Approvals * @param {ApprovalsApiApproveApprovalInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalInBulkV1(requestParameters: ApprovalsApiApproveApprovalInBulkV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.approveApprovalInBulkV1(requestParameters.bulkApproveRequestDTO, axiosOptions).then((request) => request(axios, basePath)); }, /** * Approves a specified approval request on behalf of the caller. The approval request must be in a state that allows it to be approved. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user. * @summary Post Approvals Approve * @param {ApprovalsApiApproveApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ approveApprovalV1(requestParameters: ApprovalsApiApproveApprovalV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.approveApprovalV1(requestParameters.id, requestParameters.approvalApproveRequest, axiosOptions).then((request) => request(axios, basePath)); }, /** * Cancels a specified approval requests on behalf of the caller. Note: This endpoint does not support access request IDs. To cancel access request approvals, please use the following: /access-requests/cancel * @summary Post Approval Cancel * @param {ApprovalsApiCancelApprovalByIdV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ cancelApprovalByIdV1(requestParameters: ApprovalsApiCancelApprovalByIdV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.cancelApprovalByIdV1(requestParameters.id, requestParameters.approvalCancelRequest, axiosOptions).then((request) => request(axios, basePath)); }, /** * Bulk cancels specified approval requests on behalf of the caller. Note: To bulk cancel access request approvals, please use the following: /access-requests/bulk-cancel * @summary Post Bulk Cancel Approvals * @param {ApprovalsApiCancelApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ cancelApprovalV1(requestParameters: ApprovalsApiCancelApprovalV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.cancelApprovalV1(requestParameters.bulkCancelRequestDTO, axiosOptions).then((request) => request(axios, basePath)); }, /** * Deletes an approval configuration. Configurations at the APPROVAL_REQUEST scope cannot be deleted. * @summary Delete Approval Configuration * @param {ApprovalsApiDeleteApprovalConfigRequestV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ deleteApprovalConfigRequestV1(requestParameters: ApprovalsApiDeleteApprovalConfigRequestV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.deleteApprovalConfigRequestV1(requestParameters.id, requestParameters.scope, axiosOptions).then((request) => request(axios, basePath)); }, /** * Fetches an approval request by it\'s approval ID. For lookups by access request ID please use the following: /generic-approvals?filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\" * @summary Get an approval * @param {ApprovalsApiGetApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getApprovalV1(requestParameters: ApprovalsApiGetApprovalV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getApprovalV1(requestParameters.id, axiosOptions).then((request) => request(axios, basePath)); }, /** * Retrieves a singular approval configuration that matches the given ID * @summary Get Approval Config * @param {ApprovalsApiGetApprovalsConfigV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getApprovalsConfigV1(requestParameters: ApprovalsApiGetApprovalsConfigV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.getApprovalsConfigV1(requestParameters.id, axiosOptions).then((request) => request(axios, basePath)); }, /** * Gets a list of approvals. One of the following query parameters should be present: \'mine\', \'approverId\', \'requesterId\', \'requesteeId\'. The absence of all query parameters for non admins will default to mine=true (which is the equivalent of \'approverId=[your_identity_id]\') while admins will default to mine=false (which will show all approvals in the org). For lookups by access request ID please use the following: \'/generic-approvals?mine=false&filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\"\' * @summary Get approvals * @param {ApprovalsApiGetApprovalsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ getApprovalsV1(requestParameters: ApprovalsApiGetApprovalsV1Request = {}, axiosOptions?: RawAxiosRequestConfig): AxiosPromise> { return localVarFp.getApprovalsV1(requestParameters.mine, requestParameters.requesterId, requestParameters.requesteeId, requestParameters.approverId, requestParameters.count, requestParameters.countOnly, requestParameters.includeComments, requestParameters.includeApprovers, requestParameters.includeReassignmentHistory, requestParameters.includeBatchInfo, requestParameters.filters, requestParameters.limit, requestParameters.offset, axiosOptions).then((request) => request(axios, basePath)); }, /** * Bulk reassigns specified approval requests on behalf of the caller * @summary Post Bulk Reassign Approvals * @param {ApprovalsApiMoveApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ moveApprovalV1(requestParameters: ApprovalsApiMoveApprovalV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.moveApprovalV1(requestParameters.bulkReassignRequestDTO, axiosOptions).then((request) => request(axios, basePath)); }, /** * Upserts a singular approval configuration that matches the given configID and configScope. For example to update the approval configurations for all Access Request Approvals please use: \'/generic-approvals/config/ACCESS_REQUEST_APPROVAL/APPROVAL_TYPE\' * @summary Put Approval Config * @param {ApprovalsApiPutApprovalsConfigV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ putApprovalsConfigV1(requestParameters: ApprovalsApiPutApprovalsConfigV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.putApprovalsConfigV1(requestParameters.id, requestParameters.scope, requestParameters.approvalConfig, axiosOptions).then((request) => request(axios, basePath)); }, /** * Bulk reject specified approval requests on behalf of the caller * @summary Post Bulk Reject Approvals * @param {ApprovalsApiRejectApprovalInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalInBulkV1(requestParameters: ApprovalsApiRejectApprovalInBulkV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.rejectApprovalInBulkV1(requestParameters.bulkRejectRequestDTO, axiosOptions).then((request) => request(axios, basePath)); }, /** * Rejects a specified approval request on behalf of the caller. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user and approved. * @summary Post Approvals Reject * @param {ApprovalsApiRejectApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ rejectApprovalV1(requestParameters: ApprovalsApiRejectApprovalV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.rejectApprovalV1(requestParameters.id, requestParameters.approvalRejectRequest, axiosOptions).then((request) => request(axios, basePath)); }, /** * Allows for the edit/addition/removal of the key/value pair additional attributes map for an existing approval request. This endpoint does not support access request IDs. * @summary Post Approvals Attributes * @param {ApprovalsApiUpdateApprovalsAttributesV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ updateApprovalsAttributesV1(requestParameters: ApprovalsApiUpdateApprovalsAttributesV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.updateApprovalsAttributesV1(requestParameters.id, requestParameters.approvalAttributesRequest, axiosOptions).then((request) => request(axios, basePath)); }, /** * Adds comments to a specified approval request. This endpoint does not support access request IDs. * @summary Post Approvals Comments * @param {ApprovalsApiUpdateApprovalsCommentsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ updateApprovalsCommentsV1(requestParameters: ApprovalsApiUpdateApprovalsCommentsV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.updateApprovalsCommentsV1(requestParameters.id, requestParameters.approvalCommentsRequest, axiosOptions).then((request) => request(axios, basePath)); }, /** * Reassigns an approval request to another identity resulting in that identity being added as an authorized approver. This endpoint does not support access request IDs. * @summary Post Approvals Reassign * @param {ApprovalsApiUpdateApprovalsReassignV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} */ updateApprovalsReassignV1(requestParameters: ApprovalsApiUpdateApprovalsReassignV1Request, axiosOptions?: RawAxiosRequestConfig): AxiosPromise { return localVarFp.updateApprovalsReassignV1(requestParameters.id, requestParameters.approvalReassignRequest, axiosOptions).then((request) => request(axios, basePath)); }, }; }; /** * Request parameters for approveApprovalInBulkV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiApproveApprovalInBulkV1Request */ export interface ApprovalsApiApproveApprovalInBulkV1Request { /** * * @type {BulkApproveRequestDTO} * @memberof ApprovalsApiApproveApprovalInBulkV1 */ readonly bulkApproveRequestDTO: BulkApproveRequestDTO } /** * Request parameters for approveApprovalV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiApproveApprovalV1Request */ export interface ApprovalsApiApproveApprovalV1Request { /** * Approval ID that correlates to an existing approval request that a user wants to approve. * @type {string} * @memberof ApprovalsApiApproveApprovalV1 */ readonly id: string /** * * @type {ApprovalApproveRequest} * @memberof ApprovalsApiApproveApprovalV1 */ readonly approvalApproveRequest?: ApprovalApproveRequest } /** * Request parameters for cancelApprovalByIdV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiCancelApprovalByIdV1Request */ export interface ApprovalsApiCancelApprovalByIdV1Request { /** * ID of the approval request to cancel. * @type {string} * @memberof ApprovalsApiCancelApprovalByIdV1 */ readonly id: string /** * * @type {ApprovalCancelRequest} * @memberof ApprovalsApiCancelApprovalByIdV1 */ readonly approvalCancelRequest?: ApprovalCancelRequest } /** * Request parameters for cancelApprovalV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiCancelApprovalV1Request */ export interface ApprovalsApiCancelApprovalV1Request { /** * * @type {BulkCancelRequestDTO} * @memberof ApprovalsApiCancelApprovalV1 */ readonly bulkCancelRequestDTO: BulkCancelRequestDTO } /** * Request parameters for deleteApprovalConfigRequestV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiDeleteApprovalConfigRequestV1Request */ export interface ApprovalsApiDeleteApprovalConfigRequestV1Request { /** * The ID defined by the scope field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @type {string} * @memberof ApprovalsApiDeleteApprovalConfigRequestV1 */ readonly id: string /** * The scope of the field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @type {'DOMAIN_OBJECT' | 'ROLE' | 'ACCESS_PROFILE' | 'ENTITLEMENT' | 'APPROVAL_TYPE' | 'TENANT'} * @memberof ApprovalsApiDeleteApprovalConfigRequestV1 */ readonly scope: DeleteApprovalConfigRequestV1ScopeEnum } /** * Request parameters for getApprovalV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiGetApprovalV1Request */ export interface ApprovalsApiGetApprovalV1Request { /** * ID of the approval that is to be returned * @type {string} * @memberof ApprovalsApiGetApprovalV1 */ readonly id: string } /** * Request parameters for getApprovalsConfigV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiGetApprovalsConfigV1Request */ export interface ApprovalsApiGetApprovalsConfigV1Request { /** * The id of the object the config applies to, for example one of the following: [(approvalID), (roleID), (entitlementID), (accessProfileID), \"ENTITLEMENT_DESCRIPTIONS\", \"ACCESS_REQUEST_APPROVAL\", \"ACCOUNT_CREATE_APPROVAL_REQUEST\", \"ACCOUNT_DELETE_APPROVAL_REQUEST\", \"MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST\", \"MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST\", (tenantID)] * @type {string} * @memberof ApprovalsApiGetApprovalsConfigV1 */ readonly id: string } /** * Request parameters for getApprovalsV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiGetApprovalsV1Request */ export interface ApprovalsApiGetApprovalsV1Request { /** * Determines whether to return the list of approvals assigned to the current caller or all approvals in the org. Defaults to false if admin, true otherwise (which is the equivalent of \'approverId=[your_identity_id]\'). * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly mine?: boolean /** * Returns the list of approvals for a given requester ID. Must match the calling user\'s identity ID unless they are an admin. * @type {string} * @memberof ApprovalsApiGetApprovalsV1 */ readonly requesterId?: string /** * Returns the list of approvals for a given requesteeId ID. Must match the calling user\'s identity ID unless they are an admin. * @type {string} * @memberof ApprovalsApiGetApprovalsV1 */ readonly requesteeId?: string /** * Returns the list of approvals for a given approverId ID. Must match the calling user\'s identity ID unless they are an admin. * @type {string} * @memberof ApprovalsApiGetApprovalsV1 */ readonly approverId?: string /** * Adds X-Total-Count to the header to give the amount of total approvals returned from the query. * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly count?: boolean /** * Adds X-Total-Count to the header to give the amount of total approvals returned from the query. Only returns the count and no approval objects. * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly countOnly?: boolean /** * If set to true in the query, the approval requests returned will include comments. * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly includeComments?: boolean /** * If set to true in the query, the approval requests returned will include approvers. * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly includeApprovers?: boolean /** * If set to true in the query, the approval requests returned will include reassignment history. * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly includeReassignmentHistory?: boolean /** * If set to true in the query, the approval requests returned will include batch information. * @type {boolean} * @memberof ApprovalsApiGetApprovalsV1 */ readonly includeBatchInfo?: boolean /** * Filter results using the standard syntax described in [V3 API Standard Collection Parameters](https://developer.sailpoint.com/idn/api/standard-collection-parameters#filtering-results) Filtering is supported for the following fields and operators: **status**: *eq, ne, in, co, sw* **name**: *eq, ne, in, co, sw* **priority**: *eq, ne, in, co, sw* **type**: *eq, ne, in, co, sw* **medium**: *eq, ne, in, co, sw* **description**: *eq, ne, in, co, sw* **batchId**: *eq, ne, in, co, sw* **createdDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **dueDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **completedDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **search**: *eq, ne, in, co, sw* **referenceId**: *eq, ne, in, co, sw* **referenceType**: *eq, ne, in, co, sw* **referenceName**: *eq, ne, in, co, sw* **requestedTargetId**: *eq, ne, in, co, sw* **requestedTargetType**: *eq, ne, in, co, sw* **requestedTargetName**: *eq, ne, in, co, sw* **requestedTargetRequestType**: *eq, ne, in, co, sw* **modifiedDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **decisionDate**: *eq, ne, in, co, sw, gt, ge, lt, le* **approvalId**: *eq, ne, in, co, sw* **requesterId**: *eq, ne, in, co, sw* **requesteeId**: *eq, ne, in, co, sw* **approverId**: *eq, ne, in, co, sw* * @type {string} * @memberof ApprovalsApiGetApprovalsV1 */ readonly filters?: 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 ApprovalsApiGetApprovalsV1 */ 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 ApprovalsApiGetApprovalsV1 */ readonly offset?: number } /** * Request parameters for moveApprovalV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiMoveApprovalV1Request */ export interface ApprovalsApiMoveApprovalV1Request { /** * * @type {BulkReassignRequestDTO} * @memberof ApprovalsApiMoveApprovalV1 */ readonly bulkReassignRequestDTO: BulkReassignRequestDTO } /** * Request parameters for putApprovalsConfigV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiPutApprovalsConfigV1Request */ export interface ApprovalsApiPutApprovalsConfigV1Request { /** * The ID defined by the scope field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @type {string} * @memberof ApprovalsApiPutApprovalsConfigV1 */ readonly id: string /** * The scope of the field, where [[id]]:[[scope]] is the following [[roleID]]:ROLE [[entitlementID]]:ENTITLEMENT [[accessProfileID]]:ACCESS_PROFILE ENTITLEMENT_DESCRIPTIONS:APPROVAL_TYPE ACCESS_REQUEST_APPROVAL:APPROVAL_TYPE ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_CREATE_APPROVAL_REQUEST:APPROVAL_TYPE MACHINE_ACCOUNT_DELETE_APPROVAL_REQUEST:APPROVAL_TYPE [[tenantID]]:TENANT [[domainObjectID]]:DOMAIN_OBJECT * @type {'DOMAIN_OBJECT' | 'ROLE' | 'ACCESS_PROFILE' | 'ENTITLEMENT' | 'APPROVAL_TYPE' | 'TENANT'} * @memberof ApprovalsApiPutApprovalsConfigV1 */ readonly scope: PutApprovalsConfigV1ScopeEnum /** * * @type {ApprovalConfig} * @memberof ApprovalsApiPutApprovalsConfigV1 */ readonly approvalConfig: ApprovalConfig } /** * Request parameters for rejectApprovalInBulkV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiRejectApprovalInBulkV1Request */ export interface ApprovalsApiRejectApprovalInBulkV1Request { /** * * @type {BulkRejectRequestDTO} * @memberof ApprovalsApiRejectApprovalInBulkV1 */ readonly bulkRejectRequestDTO: BulkRejectRequestDTO } /** * Request parameters for rejectApprovalV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiRejectApprovalV1Request */ export interface ApprovalsApiRejectApprovalV1Request { /** * Approval ID that correlates to an existing approval request that a user wants to reject. * @type {string} * @memberof ApprovalsApiRejectApprovalV1 */ readonly id: string /** * * @type {ApprovalRejectRequest} * @memberof ApprovalsApiRejectApprovalV1 */ readonly approvalRejectRequest?: ApprovalRejectRequest } /** * Request parameters for updateApprovalsAttributesV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiUpdateApprovalsAttributesV1Request */ export interface ApprovalsApiUpdateApprovalsAttributesV1Request { /** * Approval ID that correlates to an existing approval request that a user wants to change the attributes of. * @type {string} * @memberof ApprovalsApiUpdateApprovalsAttributesV1 */ readonly id: string /** * * @type {ApprovalAttributesRequest} * @memberof ApprovalsApiUpdateApprovalsAttributesV1 */ readonly approvalAttributesRequest: ApprovalAttributesRequest } /** * Request parameters for updateApprovalsCommentsV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiUpdateApprovalsCommentsV1Request */ export interface ApprovalsApiUpdateApprovalsCommentsV1Request { /** * Approval ID that correlates to an existing approval request that a user wants to add a comment to. * @type {string} * @memberof ApprovalsApiUpdateApprovalsCommentsV1 */ readonly id: string /** * * @type {ApprovalCommentsRequest} * @memberof ApprovalsApiUpdateApprovalsCommentsV1 */ readonly approvalCommentsRequest: ApprovalCommentsRequest } /** * Request parameters for updateApprovalsReassignV1 operation in ApprovalsApi. * @export * @interface ApprovalsApiUpdateApprovalsReassignV1Request */ export interface ApprovalsApiUpdateApprovalsReassignV1Request { /** * Approval ID that correlates to an existing approval request that a user wants to reassign. * @type {string} * @memberof ApprovalsApiUpdateApprovalsReassignV1 */ readonly id: string /** * * @type {ApprovalReassignRequest} * @memberof ApprovalsApiUpdateApprovalsReassignV1 */ readonly approvalReassignRequest: ApprovalReassignRequest } /** * ApprovalsApi - object-oriented interface * @export * @class ApprovalsApi * @extends {BaseAPI} */ export class ApprovalsApi extends BaseAPI { /** * Bulk Approves specified approval requests on behalf of the caller * @summary Post Bulk Approve Approvals * @param {ApprovalsApiApproveApprovalInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public approveApprovalInBulkV1(requestParameters: ApprovalsApiApproveApprovalInBulkV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).approveApprovalInBulkV1(requestParameters.bulkApproveRequestDTO, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Approves a specified approval request on behalf of the caller. The approval request must be in a state that allows it to be approved. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user. * @summary Post Approvals Approve * @param {ApprovalsApiApproveApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public approveApprovalV1(requestParameters: ApprovalsApiApproveApprovalV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).approveApprovalV1(requestParameters.id, requestParameters.approvalApproveRequest, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Cancels a specified approval requests on behalf of the caller. Note: This endpoint does not support access request IDs. To cancel access request approvals, please use the following: /access-requests/cancel * @summary Post Approval Cancel * @param {ApprovalsApiCancelApprovalByIdV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public cancelApprovalByIdV1(requestParameters: ApprovalsApiCancelApprovalByIdV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).cancelApprovalByIdV1(requestParameters.id, requestParameters.approvalCancelRequest, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Bulk cancels specified approval requests on behalf of the caller. Note: To bulk cancel access request approvals, please use the following: /access-requests/bulk-cancel * @summary Post Bulk Cancel Approvals * @param {ApprovalsApiCancelApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public cancelApprovalV1(requestParameters: ApprovalsApiCancelApprovalV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).cancelApprovalV1(requestParameters.bulkCancelRequestDTO, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Deletes an approval configuration. Configurations at the APPROVAL_REQUEST scope cannot be deleted. * @summary Delete Approval Configuration * @param {ApprovalsApiDeleteApprovalConfigRequestV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public deleteApprovalConfigRequestV1(requestParameters: ApprovalsApiDeleteApprovalConfigRequestV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).deleteApprovalConfigRequestV1(requestParameters.id, requestParameters.scope, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Fetches an approval request by it\'s approval ID. For lookups by access request ID please use the following: /generic-approvals?filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\" * @summary Get an approval * @param {ApprovalsApiGetApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public getApprovalV1(requestParameters: ApprovalsApiGetApprovalV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).getApprovalV1(requestParameters.id, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Retrieves a singular approval configuration that matches the given ID * @summary Get Approval Config * @param {ApprovalsApiGetApprovalsConfigV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public getApprovalsConfigV1(requestParameters: ApprovalsApiGetApprovalsConfigV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).getApprovalsConfigV1(requestParameters.id, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Gets a list of approvals. One of the following query parameters should be present: \'mine\', \'approverId\', \'requesterId\', \'requesteeId\'. The absence of all query parameters for non admins will default to mine=true (which is the equivalent of \'approverId=[your_identity_id]\') while admins will default to mine=false (which will show all approvals in the org). For lookups by access request ID please use the following: \'/generic-approvals?mine=false&filters=referenceType+eq+\"accessRequestId\"+and+referenceId+eq+\"12345678901234567890123456789012\"\' * @summary Get approvals * @param {ApprovalsApiGetApprovalsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public getApprovalsV1(requestParameters: ApprovalsApiGetApprovalsV1Request = {}, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).getApprovalsV1(requestParameters.mine, requestParameters.requesterId, requestParameters.requesteeId, requestParameters.approverId, requestParameters.count, requestParameters.countOnly, requestParameters.includeComments, requestParameters.includeApprovers, requestParameters.includeReassignmentHistory, requestParameters.includeBatchInfo, requestParameters.filters, requestParameters.limit, requestParameters.offset, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Bulk reassigns specified approval requests on behalf of the caller * @summary Post Bulk Reassign Approvals * @param {ApprovalsApiMoveApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public moveApprovalV1(requestParameters: ApprovalsApiMoveApprovalV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).moveApprovalV1(requestParameters.bulkReassignRequestDTO, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Upserts a singular approval configuration that matches the given configID and configScope. For example to update the approval configurations for all Access Request Approvals please use: \'/generic-approvals/config/ACCESS_REQUEST_APPROVAL/APPROVAL_TYPE\' * @summary Put Approval Config * @param {ApprovalsApiPutApprovalsConfigV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public putApprovalsConfigV1(requestParameters: ApprovalsApiPutApprovalsConfigV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).putApprovalsConfigV1(requestParameters.id, requestParameters.scope, requestParameters.approvalConfig, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Bulk reject specified approval requests on behalf of the caller * @summary Post Bulk Reject Approvals * @param {ApprovalsApiRejectApprovalInBulkV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public rejectApprovalInBulkV1(requestParameters: ApprovalsApiRejectApprovalInBulkV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).rejectApprovalInBulkV1(requestParameters.bulkRejectRequestDTO, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Rejects a specified approval request on behalf of the caller. This endpoint does not support access request IDs. If called by an admin and the admin is not listed as an approver, the approval request will be reassigned from a random approver to the admin user and approved. * @summary Post Approvals Reject * @param {ApprovalsApiRejectApprovalV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public rejectApprovalV1(requestParameters: ApprovalsApiRejectApprovalV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).rejectApprovalV1(requestParameters.id, requestParameters.approvalRejectRequest, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Allows for the edit/addition/removal of the key/value pair additional attributes map for an existing approval request. This endpoint does not support access request IDs. * @summary Post Approvals Attributes * @param {ApprovalsApiUpdateApprovalsAttributesV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public updateApprovalsAttributesV1(requestParameters: ApprovalsApiUpdateApprovalsAttributesV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).updateApprovalsAttributesV1(requestParameters.id, requestParameters.approvalAttributesRequest, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Adds comments to a specified approval request. This endpoint does not support access request IDs. * @summary Post Approvals Comments * @param {ApprovalsApiUpdateApprovalsCommentsV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public updateApprovalsCommentsV1(requestParameters: ApprovalsApiUpdateApprovalsCommentsV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).updateApprovalsCommentsV1(requestParameters.id, requestParameters.approvalCommentsRequest, axiosOptions).then((request) => request(this.axios, this.basePath)); } /** * Reassigns an approval request to another identity resulting in that identity being added as an authorized approver. This endpoint does not support access request IDs. * @summary Post Approvals Reassign * @param {ApprovalsApiUpdateApprovalsReassignV1Request} requestParameters Request parameters. * @param {*} [axiosOptions] Override http request option. * @throws {RequiredError} * @memberof ApprovalsApi */ public updateApprovalsReassignV1(requestParameters: ApprovalsApiUpdateApprovalsReassignV1Request, axiosOptions?: RawAxiosRequestConfig) { return ApprovalsApiFp(this.configuration).updateApprovalsReassignV1(requestParameters.id, requestParameters.approvalReassignRequest, axiosOptions).then((request) => request(this.axios, this.basePath)); } } /** * @export */ export const DeleteApprovalConfigRequestV1ScopeEnum = { DomainObject: 'DOMAIN_OBJECT', Role: 'ROLE', AccessProfile: 'ACCESS_PROFILE', Entitlement: 'ENTITLEMENT', ApprovalType: 'APPROVAL_TYPE', Tenant: 'TENANT' } as const; export type DeleteApprovalConfigRequestV1ScopeEnum = typeof DeleteApprovalConfigRequestV1ScopeEnum[keyof typeof DeleteApprovalConfigRequestV1ScopeEnum]; /** * @export */ export const PutApprovalsConfigV1ScopeEnum = { DomainObject: 'DOMAIN_OBJECT', Role: 'ROLE', AccessProfile: 'ACCESS_PROFILE', Entitlement: 'ENTITLEMENT', ApprovalType: 'APPROVAL_TYPE', Tenant: 'TENANT' } as const; export type PutApprovalsConfigV1ScopeEnum = typeof PutApprovalsConfigV1ScopeEnum[keyof typeof PutApprovalsConfigV1ScopeEnum];