[]
        
(Showing Draft Content)

Scheduler

Scheduler

[POST] /api/v2/scheduler/tasks

Create task

Request Body

Description: Scheduled task info

Type: application/json

CreateTaskRequestViewModel

Responses

[200] Success

CreateTaskResponseViewModel

Type: [application/json]

[400] Bad Request

SchedulerPluginErrorConsts

Type: [application/json]

[POST] /api/v2/scheduler/tasks/batch-delete

Batch delete the specified tasks.

Request Body

Type: application/json

RemoveTasksRequestModel

Responses

[200] Success

RemoveTasksResponseModel

Type: [application/json]

[400] Bad Request

SchedulerPluginErrorConsts

Type: [application/json]

Models

Ƭ CreateTaskResponseViewModel

Response view model for a created scheduled task. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.ScheduledTaskInfoDTO in the response for API isolation.

Name Type Description Example
templateIdNullable string The template identifier for the task configuration. "tpl-monthly-report"
descriptionNullable string The description of the scheduled task. "Monthly sales report export"
failInformEmailNullable string Legacy email address for failure notifications. "admin@example.com"
failInformProvider TaskFailInformProviderViewModel
isActiveNullable Boolean Indicates whether the task is active. true
task TaskInfoViewModel
tasks TaskInfoArrayViewModel
documentIdNullable string The document identifier associated with the task. "doc-abc123"
trigger RecurrenceViewModel
deployTo DeployTargetViewModel
operationTypeNullable string The operation type for the task. "Append"
locationNullable string The location for the task operation. "/data/reports"
dataUpdateMode DataUpdateModeViewModel
historyDataExpiryDurationNullable string The duration for history data expiry. "P30D"
compoundTaskNullable Boolean Indicates whether this is a compound task. false
runAs RunAsViewModel

Ƭ TaskFailInformProviderViewModel

View model for the task failure notification provider configuration. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.TaskFailInformProviderDTO for API isolation.

Name Type
emailProvider TaskFailInformEmailProviderViewModel
appMsgProvider TaskFailInformAppMsgProviderViewModel

Ƭ TaskInfoViewModel

View model for individual task information. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.TaskInfoDTO for API isolation. Excludes StatusBeforeSoftDeleted (internal state).

Name Type Description Example
taskType TaskTypeViewModel
payloadNullable string The task payload data.
parametersNullable string The task parameters.
userDetails UserDetailsViewModel
documentIdNullable string The document identifier associated with the task. "doc-abc123"

Ƭ TaskInfoArrayViewModel

View model for an array of task information (compound tasks). Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.TaskInfoArrayDTO for API isolation.

Name Type Description
userDetails UserDetailsViewModel
taskInfosNullable Array<TaskInfoViewModel> The array of individual task information entries.

Ƭ RecurrenceViewModel

View model for recurrence/trigger configuration. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.RecurrenceDTO for API isolation.

Name Type Description Example
type RecurrenceDtoTypeViewModel
onceNullable ISO DateTime Sting The date and time for a one-time trigger. "2025-06-15T10:30:00Z"
onceTimeZoneIdNullable string The time zone identifier for the one-time trigger. "America/New_York"
pattern RecurrenceInfoViewModel
templateIdNullable string The template identifier for template-based scheduling. "tpl-daily-report"
explicitNullable Boolean Indicates whether this is an explicit (manual) trigger. true

Ƭ DeployTargetViewModel

View model for deployment target configuration. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.DeployTargetDTO for API isolation. Only one field should be non-null at a time — the Type property is computed accordingly.

Name Type Description Example
type DeployTargetDtoTypeViewModel
templateIdNullable string The template identifier for template-based deployment. "tpl-email-pdf"
smb SmbViewModel
localStore LocalStoreViewModel
serverPrinter ServerPrinterViewModel
emailAttach EmailAttachViewModel
emailLink EmailLinkViewModel
emailBody EmailBodyViewModel
appOnlineLinkNotification AppOnlineLinkNotificationViewModel
appDownloadLinkNotification AppDownloadLinkNotificationViewModel
emailDownloadLink EmailDownloadLinkViewModel
externalStorage ExternalStorageViewModel

Ƭ DataUpdateModeViewModel

Enum:

  • Override

  • IncrementalUpdate

    Specifies the data update mode for a scheduled task.
    Replaces for API isolation.

    * Override - 0 - Override existing data.
    * IncrementalUpdate - 1 - Incrementally update existing data.

Ƭ RunAsViewModel

View model for the "run as" user configuration of a scheduled task. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.RunAsDTO for API isolation.

Name Type Description Example
userIdNullable string The unique identifier of the user to run the task as. "d4e5f6a7-b8c9-0d1e-2f3a-4b5c6d7e8f90"
usernameNullable string The username of the user to run the task as. "jane.smith"
organizationIdNullable string The organization identifier the run-as user belongs to. "c1d2e3f4-a5b6-7890-cdef-1234567890ab"
providerNullable string The authentication provider for the run-as user. "local"

Ƭ TaskFailInformEmailProviderViewModel

View model for the email provider configuration in task failure notifications. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.TaskFailInformEmailProviderDTO for API isolation.

Name Type Description Example
emailAddressNullable string The primary email address for failure notifications. "admin@example.com"

Ƭ TaskFailInformAppMsgProviderViewModel

View model for the app message provider in task failure notifications. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.TaskFailInformAppMsgProviderDTO for API isolation.

Name Type Description Example
appNameNullable string The application name for the notification. "ReportPortal"
message AppMessageViewModel

Ƭ AppMessageViewModel

View model for application messages used in task failure notifications. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.AppMessageDTO for API isolation.

Name Type Description
recipientsNullable Array<AppMessageRecipientViewModel> The list of message recipients.

Ƭ AppMessageRecipientViewModel

View model for an application message recipient. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.AppMessageRecipientDTO for API isolation.

Name Type Description Example
addressNullable string The address of the message recipient. "user@example.com"
addressTypeNullable string The type of the address. "email"
displayNameNullable string The display name of the recipient. "John Doe"

Ƭ TaskTypeViewModel

Enum:

  • RptExport

  • DatasetRefresh

  • DashboardExport

  • DataSourceExtract

  • DatasetCleanup

  • DataModelRefresh

  • CompoundTask

  • RptPreviewCache

  • DataflowRefresh

  • RptServerPrint

  • InternalSchedule

    Specifies the type of scheduled task.
    Replaces for API isolation.

    * RptExport - 0 - Report export task.
    * DatasetRefresh - 1 - Dataset refresh task.
    * DashboardExport - 2 - Dashboard export task.
    * DataSourceExtract - 3 - Data source extract task.
    * DatasetCleanup - 4 - Dataset cleanup task.
    * DataModelRefresh - 5 - Data model refresh task.
    * CompoundTask - 6 - Compound task combining multiple sub-tasks.
    * RptPreviewCache - 7 - Report preview cache task.
    * DataflowRefresh - 8 - Dataflow refresh task.
    * RptServerPrint - 9 - Report server print task.
    * InternalSchedule - 99 - Internal schedule task.

Ƭ UserDetailsViewModel

View model for user details used when creating or updating a scheduled task. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.UserDetailsDTO for API isolation. Excludes EncryptedRefreshToken for security.

Name Type Description Example
idNullable string The unique identifier of the user. "b3f1a2c4-5d6e-7f89-0a1b-2c3d4e5f6a7b"
nameNullable string The display name of the user. "John Doe"
providerNullable string The authentication provider for the user. "local"
tenantIdNullable string The tenant identifier the user belongs to. "a1b2c3d4-e5f6-7890-abcd-ef1234567890"
createdByIntegrationNullable Boolean Indicates whether this user was created by an integration. false

Ƭ RecurrenceDtoTypeViewModel

Enum:

  • Once

  • Pattern

  • TemplateId

  • Explicit

    Specifies the recurrence type of a trigger.
    Replaces for API isolation.

    * Once - 0 - Run once at a specified time.
    * Pattern - 1 - Run on a recurring cron pattern.
    * TemplateId - 2 - Run using a template-defined schedule.
    * Explicit - 3 - Run only when explicitly triggered.

Ƭ RecurrenceInfoViewModel

View model for recurrence pattern information. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.RecurrenceInfoDTO for API isolation.

Name Type Description Example
patternsNullable Array<string> The list of cron expression patterns defining the recurrence schedule. ["0 0 8 * * ?"]
startDateNullable ISO DateTime Sting The start date of the recurrence range. "2025-01-01T00:00:00Z"
endDateNullable ISO DateTime Sting The end date of the recurrence range. "2025-12-31T23:59:59Z"
timeZoneIdNullable string The IANA time zone identifier for the recurrence schedule. "America/New_York"

Ƭ DeployTargetDtoTypeViewModel

Enum:

  • TemplateId

  • Smb

  • EmailAttach

  • EmailLink

  • LocalStore

  • EmailBody

  • AppOnlineLinkNotification

  • EmailDownloadLink

  • AppDownloadLinkNotification

  • ExternalStorage

  • ServerPrinter

    Specifies the type of deployment target.
    Replaces for API isolation.

    * TemplateId - 0 - Template-based deployment.
    * Smb - 1 - SMB/network share deployment.
    * EmailAttach - 2 - Email with attachment.
    * EmailLink - 3 - Email with link.
    * LocalStore - 4 - Local storage.
    * EmailBody - 5 - Email with body content.
    * AppOnlineLinkNotification - 6 - App online link notification.
    * EmailDownloadLink - 7 - Email with download link.
    * AppDownloadLinkNotification - 8 - App download link notification.
    * ExternalStorage - 9 - External storage.
    * ServerPrinter - 10 - Server printer.

Ƭ SmbViewModel

View model for SMB/network share delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.SmbDTO for API isolation.

Name Type Description Example
filenameNullable string The filename for the delivered file. "report_2025.pdf"
overwriteNullable Boolean Indicates whether to overwrite an existing file. true
fullPathNullable string The full UNC path for the SMB share.

Ƭ LocalStoreViewModel

View model for local storage delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.LocalStoreDTO for API isolation.

Name Type Description Example
allowAnonymousNullable Boolean Indicates whether anonymous access is allowed. false
storePolicy LocalStorePolicyViewModel

Ƭ ServerPrinterViewModel

View model for server printer delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.ServerPrinterDTO for API isolation.

Name Type Description Example
printerNameNullable string The name of the printer. "Office Laser Printer"
printerIdNullable string The unique identifier of the printer. "printer-001"
printerSettings ServerPrinterSettingsViewModel

Ƭ EmailAttachViewModel

View model for email-with-attachment delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.EmailAttachDTO for API isolation.

Name Type
settings EmailSettingsViewModel
localStore LocalStoreViewModel

Ƭ EmailLinkViewModel

View model for email-link delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.EmailLinkDTO for API isolation.

Name Type
settings EmailSettingsViewModel
localStore LocalStoreViewModel

Ƭ EmailBodyViewModel

View model for email-body delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.EmailBodyDTO for API isolation.

Name Type
settings EmailSettingsViewModel
localStore LocalStoreViewModel

Ƭ AppOnlineLinkNotificationViewModel

View model for app online-link notification delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.AppOnlineLinkNotificationDTO for API isolation.

Name Type
settings AppNotificationSettingsViewModel
localStore LocalStoreViewModel

Ƭ AppDownloadLinkNotificationViewModel

View model for app download-link notification delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.AppDownloadLinkNotificationDTO for API isolation.

Name Type
settings AppNotificationSettingsViewModel
localStore LocalStoreViewModel

Ƭ EmailDownloadLinkViewModel

View model for email-download-link delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.EmailDownloadLinkDTO for API isolation.

Name Type
settings EmailSettingsViewModel
localStore LocalStoreViewModel

Ƭ ExternalStorageViewModel

View model for external storage delivery target. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.ExternalStorageDTO for API isolation.

Name Type Description Example
storageIdNullable string The unique identifier of the external storage. "es-001"
storageTypeNullable string The type of external storage. "AzureBlob"
storageNameNullable string The display name of the external storage. "Azure Reports Blob"

Ƭ LocalStorePolicyViewModel

View model for local storage retention policy. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.LocalStorePolicyDTO for API isolation.

Name Type Description Example
type LocalStorePolicyDtoTypeViewModel
foreverNullable Boolean Indicates whether to store content forever. true
storeUntilNullable ISO DateTime Sting The date until which to store content. "2026-01-01T00:00:00Z"
deleteAfterNullable int32 The numeric span after which to delete content. 30
unit DeleteAfterUnitViewModel
deleteAfterSlidingNullable string A sliding time window after which to delete content. "7.00:00:00"

Ƭ LocalStorePolicyDtoTypeViewModel

Enum:

  • Forever

  • StoreUntil

  • DeleteAfter

    Specifies the type of local store policy.
    Replaces for API isolation.

    * Forever - 0 - Store forever.
    * StoreUntil - 1 - Store until a specific date.
    * DeleteAfter - 2 - Delete after a duration.

Ƭ DeleteAfterUnitViewModel

Enum:

  • Hour

  • Day

  • Week

  • Month

  • Year

    Specifies the unit of time for delete-after policies.
    Replaces for API isolation.

    * Hour - 0 - Hours.
    * Day - 1 - Days.
    * Week - 2 - Weeks.
    * Month - 3 - Months.
    * Year - 4 - Years.

Ƭ ServerPrinterSettingsViewModel

View model for server printer settings. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.ServerPrinterSettingsDTO for API isolation.

Name Type Description Example
duplexNullable string The duplex printing mode. "Simplex"
collate Boolean Indicates whether to collate printed copies. true
fromPageNullable int32 The starting page number for printing. 1
toPageNullable int32 The ending page number for printing. 10
copies int32 The number of copies to print. 1
useColorNullable Boolean Indicates whether to print in color. true

Ƭ EmailSettingsViewModel

View model for email delivery settings. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.DeployTarget.EmailSettings for API isolation.

Name Type Description Example
mailToNullable Array<string> The list of primary recipient email addresses. ["user@example.com"]
subjectNullable string The email subject line. "Monthly Report - June 2025"
bodyNullable string The email body content. "Please find the attached report."
bodyForEmptyDocumentNullable string The email body content used when the document is empty. "The report generated no data."
replyToNullable string The reply-to email address. "noreply@example.com"
useRichText Boolean Indicates whether to use rich text (HTML) for the email body. true
allowUserChangeEmailTo Boolean Indicates whether the user is allowed to change the email To addresses. false
ccNullable Array<string> The list of CC (carbon copy) email addresses. ["manager@example.com"]
bccNullable Array<string> The list of BCC (blind carbon copy) email addresses. ["audit@example.com"]
allowUserChangeCc Boolean Indicates whether the user is allowed to change the CC addresses. false
allowUserChangeBcc Boolean Indicates whether the user is allowed to change the BCC addresses. false

Ƭ AppNotificationSettingsViewModel

View model for application notification settings used in delivery. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.AppNotificationSettingsDTO for API isolation.

Name Type Description Example
appNameNullable string The application name for the notification. "ReportPortal"
message AppNotificationMessageViewModel

Ƭ AppNotificationMessageViewModel

View model for application notification messages used in delivery. Replaces Grapecity.Enterprise.Server.Scheduler.Delivery.AppNotificationMessageDTO for API isolation.

Name Type Description Example
subjectNullable string The notification subject. "Report Ready"
bodyNullable string The notification body content. "Your scheduled report is now available."
urlNullable string The URL associated with the notification. "https://portal.example.com/reports/123"
recipientsNullable Array<AppMessageRecipientViewModel> The list of notification recipients.

Ƭ SchedulerPluginErrorConsts

Name Type

Ƭ CreateTaskRequestViewModel

Request view model for creating a scheduled task. Replaces Grapecity.Enterprise.Server.Scheduler.Schedule.ScheduledTaskInfoDTO as the [FromBody] parameter for API isolation. Excludes InternalScheduleKey (internal-only field).

Name Type Description Example
templateIdNullable string The template identifier for the task configuration. "tpl-monthly-report"
descriptionNullable string The description of the scheduled task. "Monthly sales report export"
failInformEmailNullable string Legacy email address for failure notifications. "admin@example.com"
failInformProvider TaskFailInformProviderViewModel
isActiveNullable Boolean Indicates whether the task is active. true
task TaskInfoViewModel
tasks TaskInfoArrayViewModel
documentIdNullable string The document identifier associated with the task. "doc-abc123"
trigger RecurrenceViewModel
deployTo DeployTargetViewModel
operationTypeNullable string The operation type for the task. "Append"
locationNullable string The location for the task operation. "/data/reports"
dataUpdateMode DataUpdateModeViewModel
historyDataExpiryDurationNullable string The duration for history data expiry. "P30D"
compoundTaskNullable Boolean Indicates whether this is a compound task. false
runAs RunAsViewModel

Ƭ RemoveTasksResponseModel

Remove tasks response model

Name Type Description Example
removeTasksIdNullable Array<string> Removed tasks id. ["8F945F0E-C7F6-0BF0-C53A-985B325D30BB","20051330-1144-3470-5DEF-A0003B051A8B"]
errorsNullable Array<ErrorContentViewModel> Errors.

Ƭ ErrorContentViewModel

Error content model

Name Type Description
code TaskErrorCodeEnumViewModel
messageNullable string Error message
contextNullable any Error context

Ƭ TaskErrorCodeEnumViewModel

Enum:

  • PermissionRequiredErrorCode

  • DocumentNotFoundErrorCode

  • OwnerRequiredErrorCode

  • TaskInvalidErrorCode

  • TaskInvalidWithTimeErrorCode

  • TaskInvalidWithEmailErrorCode

  • TaskNotFoundErrorCode

  • InvalidTaskDataErrorCode

  • TaskInvalidWithIdErrorCode

  • TaskDatasourceAppendInvalidErrorCode

  • TaskDatasourceLocationInvalidErrorCode

  • TaskDatasourceOperationInvalidErrorCode

  • WritePermissionRequireErrorCode

  • DeletePermissionRequireErrorCode

  • DirectoryInvalidErrorCode

  • DirectorySameErrorCode

  • ReadPermissionRequireErrorCode

  • NotDeliveredErrorCode

  • NoManualAndOneTimeTaskPermissionErrorCode

  • NoFileShareDeliveryPermissionErrorCode

  • PortalUriNotSetErrorCode

  • PortalUriNotSetInDataSourceErrorCode

  • PortalUriNotSetInDatasetErrorCode

  • DuplicateScheduleTaskErrorCode

  • ExpiredTaskErrorCode

  • RemoveTaskFailedErrorCode

  • TemplateNotExistsErrorCode

  • NoExportReportErrorCode

  • CreateTaskRuntimeFailedErrorCode

  • RunTaskRuntimeFailedErrorCode

  • UpdateTaskRuntimeFailedErrorCode

  • DuplicateTaskRuntimeFailedErrorCode

    Task error code enum view model

    * PermissionRequiredErrorCode - 30001 - Permission Required.
    * DocumentNotFoundErrorCode - 30002 - Document not found.
    * OwnerRequiredErrorCode - 30003 - Administrator or document owner required.
    * TaskInvalidErrorCode - 30004 - Failed to create task - task is invalid.
    * TaskInvalidWithTimeErrorCode - 30005 - Failed to create task - Store until is earlier than start time.
    * TaskInvalidWithEmailErrorCode - 30006 - Failed to create task - recipients email address outside your organization.
    * TaskNotFoundErrorCode - 30007 - Task not found.
    * InvalidTaskDataErrorCode - 30008 - Invalid task data provided.
    * TaskInvalidWithIdErrorCode - 30009 - Task invalid.
    * TaskDatasourceAppendInvalidErrorCode - 30010 - DataSource can't append data.
    * TaskDatasourceLocationInvalidErrorCode - 30011 - Location not exists.
    * TaskDatasourceOperationInvalidErrorCode - 30012 - Operation is invalid.
    * WritePermissionRequireErrorCode - 30013 - Write Permission Required.
    * DeletePermissionRequireErrorCode - 30014 - Delete Permission Required.
    * DirectoryInvalidErrorCode - 30015 - Directory invalid.
    * DirectorySameErrorCode - 30016 - Each schedule should correspond to a separate directory.
    * ReadPermissionRequireErrorCode - 30017 - Read Permission Required.
    * NotDeliveredErrorCode - 30018 - Not delivered.
    * NoManualAndOneTimeTaskPermissionErrorCode - 30019 - No manual and one-time task permission.
    * NoFileShareDeliveryPermissionErrorCode - 30020 - No file share delivery permission.
    * PortalUriNotSetErrorCode - 30021 - Portal URI not set.
    * PortalUriNotSetInDataSourceErrorCode - 30022 - Portal URI not set in data source.
    * PortalUriNotSetInDatasetErrorCode - 30023 - Portal URI not set in dataset.
    * DuplicateScheduleTaskErrorCode - 30024 - Duplicate schedule task.
    * ExpiredTaskErrorCode - 30025 - Expired task.
    * RemoveTaskFailedErrorCode - 30026 - Remove task failed.
    * TemplateNotExistsErrorCode - 30027 - Template used in this task did not exist.
    * NoExportReportErrorCode - 30028 - User has no permission to export report.
    * CreateTaskRuntimeFailedErrorCode - 30029 - An unknown error occurred while creating a task.
    * RunTaskRuntimeFailedErrorCode - 30030 - An unknown error occurred while running a task.
    * UpdateTaskRuntimeFailedErrorCode - 30031 - An unknown error occurred while updating a task.
    * DuplicateTaskRuntimeFailedErrorCode - 30032 - An unknown error occurred while duplicating a task.

Ƭ RemoveTasksRequestModel

Remove tasks request model by taskIds and task-created userIds. At least one of taskIds or userIds is required.

Name Type Description Example
taskIdsNullable Array<string> Task id list. ["8F945F0E-C7F6-0BF0-C53A-985B325D30BB","20051330-1144-3470-5DEF-A0003B051A8B"]
userIdsNullable Array<string> Task created user id. ["5536F73E-13EA-9D92-DDD5-4077CA29F04D","E86F8321-A317-DE6B-FC0C-DC0F635AA7B8"]