Warning
Helix documentation is moving from docs.bmc.com to docs.helixops.ai

Key pages will redirect to the new domain on May 26, 2026. However, some legacy documentation links will not be redirected. 

In-product help links might not work after migration as we transition and update them within the product.

For any queries, reach out to IX-Support@helixops.ai.

Job - addOneTimeScheduleWithEMailNotification


Job - addOneTimeScheduleWithEMailNotification

Description :

This command adds a one-time schedule to a job and, depending on the resulting status of the job run, issues an email notification. If approval is enabled for the job type, use the addOneTimeScheduleWithEMailNotificationAndWithApproval command instead.

The argument jobKey is a handle to the job being modified. To find the jobKey for a specific job type, use the SnapshotJob getDBKeyByGroupAndName command.

The dateString argument defines a one-time schedule to be added. It must be in the format YYYY-MM-DD HH:MM:SS.

The recipient argument identifies the receiver of the email that this command generates. The statusType argument determines the statuses for which you want to issue a notification. The possible statuses each have a value as follows:

  • Success=2
  • Failure=4
  • Cancel=8

For statusType, add the statuses for which you want to issue notifications. For example, if you want to issue notifications when the job status is Failure or Cancel, then statusType=12.

Return type : java.lang.Object

Command Input :

Variable Name

Variable Type

Description

jobKey

com.bladelogic.om.infra.model.base.keys.SJobKey

Handle to the job.

dateString

String

One-time schedule to be added. The date string must be in the format YYYY-MM-DD HH:MM:SS.

recipient

String

Receiver of the email notification.

statusType

Integer

Sum of all statuses for which you want to issue notifications. See above for a more complete description.

Example

The following example shows how to add a schedule to a job for a single run on the 1st of January 2005 at 11:35 PM. Email will be sent on success, failure, or cancel.

Script





RECIPIENT="datacenteradmin@anundisclosedcompany.com"

NOTIFICATION_STATUS=14

DATE_STRING="2005-01-01 23:35:00"

JOB_KEY=`blcli SnapshotJob getDBKeyByGroupAndName /snapshots snapconfig`

JOB_KEY=`blcli Job addOneTimeScheduleWithEMailNotification $JOB_KEY "$DATE_STRING" $RECIPIENT $NOTIFICATION_STATUS`



 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

TrueSight Server Automation Command Line Interface 23.4