Configure a Schedule Trigger

You're viewing Apigee X documentation.
View Apigee Edge documentation.

The Schedule Trigger lets you run your integration periodically at specific time intervals. This trigger is useful when you want to run your integration automatically without any manual intervention. For example, you can consider using the Schedule Trigger for the following type of tasks:

  • Uploading files from one system to another system at regular intervals
  • Sending periodic email reminders
  • Syncing database at regular intervals

Add a Schedule Trigger

To add a Schedule Trigger to a new or existing integration, follow the steps below:
  1. Go to the Apigee UI and sign in.
  2. Select your organization using the drop-down menu in the upper left corner of the UI.
  3. Click Develop > Integrations to view the list of available integrations.

  4. Select an existing integration or click Create new
  5. In the integration designer, click + Add a task/trigger to view the task and trigger selection dialog.
  6. Click Triggers to view the available triggers.
  7. Drag the Schedule Trigger element to the designer.

Configure a Schedule Trigger

Click the Schedule Trigger element in the integration designer to view the trigger configuration pane.

You can configure the Schedule Trigger using either of the following modes:

  • Basic: Provides a user interface to configure the frequency of the run.
  • Advanced: Uses a cron expression to configure the frequency of the run.

In Basic mode, you can choose to run the integration at a specific time or at hourly intervals. If you want to run the integration at a specific time, select the Run at a specific time from the Times drop-down and set the following properties:

  • Time: The time (in 24-hour format) at which the integration must run.
  • Days: The days on which the integration must run. You can select to run the integration every day, on specific days of the week, on a specific day of the month, etc.
  • Months: The month(s) in which the integration must run. You can run the integration every month or choose specific months.

In Advanced mode, you can specify the frequency of the run using a cron expression. The cron expression has five values that must be specified in the following order:

  • Minute (0-59)
  • Hour (0-23)
  • Day of the month (1-31)
  • Month, either of the following values:
    • A number 1-12
    • A three-letter month abbreviation (e.g. Jan, Feb, Mar, etc.)
  • Day of week, either of the following values:
    • A number from 0 - 6 starting with Sunday as 0
    • A three-letter day abbreviation (e.g. Mon, Tue, Wed, etc.)

For example, to run the integration on the first day of every month, use the * * 1 * * cron expression.

Best practices

As a best practice, deactivate Schedule Triggers when they are no longer needed. If you leave a redundant Schedule Trigger active, it will continue to trigger the integration automatically.

To deactivate a Schedule Trigger, you can do one of the following:

  • Unpublish the integration containing the Schedule Trigger. Your integration will no longer be active and the trigger will not run.
  • Replace the Schedule Trigger with a different trigger and re-publish the integration. The re-published, active version of the integration will not use the Schedule Trigger.
  • Delete the current version of the integration. You can find the Delete option under the version list next to the integration name.