Send feedback
Cloud Scheduler API Connector Overview
Stay organized with collections
Save and categorize content based on your preferences.
The Workflows connector defines the built-in
functions that can be used to access other Google Cloud products within a
workflow.
This page provides an overview of the individual connector.
There is no need to import or load connector libraries in a workflow—connectors
work out of the box when used in a call step.
Cloud Scheduler API
Creates and manages jobs run on a regular recurring schedule.
To learn more, see the Cloud Scheduler API documentation .
Cloud Scheduler connector sample
Module: googleapis.cloudscheduler.v1.projects.locations
Functions
get
Gets information about a location.
list
Lists information about the supported locations for this service.
Module: googleapis.cloudscheduler.v1.projects.locations.jobs
Functions
create
Creates a job.
delete
Deletes a job.
get
Gets a job.
list
Lists jobs.
patch
Updates a job. If successful, the updated Job is returned. If the job
does not exist, NOT_FOUND
is returned. If UpdateJob does not
successfully return, it is possible for the job to be in an
Job.State.UPDATE_FAILED state. A job in this state may not be executed.
If this happens, retry the UpdateJob request until a successful response
is received.
pause
Pauses a job. If a job is paused then the system will stop executing the
job until it is re-enabled via ResumeJob. The state of the job is stored
in state; if paused it will be set to Job.State.PAUSED. A job must be in
Job.State.ENABLED to be paused.
resume
Resume a job. This method reenables a job after it has been
Job.State.PAUSED. The state of a job is stored in Job.state; after
calling this method it will be set to Job.State.ENABLED. A job must be
in Job.State.PAUSED to be resumed.
run
Forces a job to run now. When this method is called, Cloud Scheduler
will dispatch the job, even if the job is already running.
Module: googleapis.cloudscheduler.v1beta1.projects.locations
Functions
get
Gets information about a location.
list
Lists information about the supported locations for this service.
Module: googleapis.cloudscheduler.v1beta1.projects.locations.jobs
Functions
create
Creates a job.
delete
Deletes a job.
get
Gets a job.
list
Lists jobs.
patch
Updates a job. If successful, the updated Job is returned. If the job
does not exist, NOT_FOUND
is returned. If UpdateJob does not
successfully return, it is possible for the job to be in an
Job.State.UPDATE_FAILED state. A job in this state may not be executed.
If this happens, retry the UpdateJob request until a successful response
is received.
pause
Pauses a job. If a job is paused then the system will stop executing the
job until it is re-enabled via ResumeJob. The state of the job is stored
in state; if paused it will be set to Job.State.PAUSED. A job must be in
Job.State.ENABLED to be paused.
resume
Resume a job. This method reenables a job after it has been
Job.State.PAUSED. The state of a job is stored in Job.state; after
calling this method it will be set to Job.State.ENABLED. A job must be
in Job.State.PAUSED to be resumed.
run
Forces a job to run now. When this method is called, Cloud Scheduler
will dispatch the job, even if the job is already running.
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-09-09 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-09 UTC."],[],[],null,["# Cloud Scheduler API Connector Overview\n\nThe Workflows connector defines the built-in\nfunctions that can be used to access other Google Cloud products within a\nworkflow.\n\nThis page provides an overview of the individual connector.\nThere is no need to import or load connector libraries in a workflow---connectors\nwork out of the box when used in a call step.\n\nCloud Scheduler API\n-------------------\n\nCreates and manages jobs run on a regular recurring schedule.\nTo learn more, see the [Cloud Scheduler API documentation](https://cloud.google.com/scheduler/).\n\nCloud Scheduler connector sample\n--------------------------------\n\n### YAML\n\n # This workflow demonstrates how to use the Cloud Scheduler connector:\n # Create a Pub/Sub topic and subscription for notifications\n # Create a Cloud Scheduler job that runs every minute and publishes\n # a message to the Pub/Sub topic when finished\n # Retrieve message from the subscription and then delete all resources\n # Expected output: \"SUCCESS\"\n - init:\n assign:\n - project_id: ${sys.get_env(\"GOOGLE_CLOUD_PROJECT_ID\")}\n - location_id: \"us-central1\"\n - job_id: \"example-job-id\"\n - topic: \"example-topic-id\"\n - subscription: \"example-subscription-id\"\n - create_topic:\n call: googleapis.pubsub.v1.projects.topics.create\n args:\n name: ${\"projects/\" + project_id + \"/topics/\" + topic}\n - create_subscription_to_topic:\n call: googleapis.pubsub.v1.projects.subscriptions.create\n args:\n name: ${\"projects/\" + project_id + \"/subscriptions/\" + subscription}\n body:\n name: ${\"projects/\" + project_id + \"/subscriptions/\" + subscription}\n topic: ${\"projects/\" + project_id + \"/topics/\" + topic}\n - create_job:\n call: googleapis.cloudscheduler.v1.projects.locations.jobs.create\n args:\n parent: ${\"projects/\" + project_id + \"/locations/\" + location_id}\n body:\n name: ${\"projects/\" + project_id + \"/locations/\" + location_id + \"/jobs/\" + job_id}\n description: \"An example job created by Workflows to test the Cloud Scheduler connector.\"\n schedule: \"* * * * *\" # runs job every minute\n pubsubTarget:\n topicName: ${\"projects/\" + project_id + \"/topics/\" + topic}\n attributes:\n job: \"finished!\"\n - sleep:\n call: sys.sleep\n args:\n seconds: 100 # sleeps for 100 seconds to allow job to run\n - pull_message:\n call: googleapis.pubsub.v1.projects.subscriptions.pull\n args:\n subscription: ${\"projects/\" + project_id + \"/subscriptions/\" + subscription}\n body:\n maxMessages: 1\n - delete_job:\n call: googleapis.cloudscheduler.v1.projects.locations.jobs.delete\n args:\n name: ${\"projects/\" + project_id + \"/locations/\" + location_id + \"/jobs/\" + job_id}\n - delete_subscription:\n call: googleapis.pubsub.v1.projects.subscriptions.delete\n args:\n subscription: ${\"projects/\" + project_id + \"/subscriptions/\" + subscription}\n - delete_topic:\n call: googleapis.pubsub.v1.projects.topics.delete\n args:\n topic: ${\"projects/\" + project_id + \"/topics/\" + topic}\n - the_end:\n return: \"SUCCESS\"\n\n### JSON\n\n [\n {\n \"init\": {\n \"assign\": [\n {\n \"project_id\": \"${sys.get_env(\\\"GOOGLE_CLOUD_PROJECT_ID\\\")}\"\n },\n {\n \"location_id\": \"us-central1\"\n },\n {\n \"job_id\": \"example-job-id\"\n },\n {\n \"topic\": \"example-topic-id\"\n },\n {\n \"subscription\": \"example-subscription-id\"\n }\n ]\n }\n },\n {\n \"create_topic\": {\n \"call\": \"googleapis.pubsub.v1.projects.topics.create\",\n \"args\": {\n \"name\": \"${\\\"projects/\\\" + project_id + \\\"/topics/\\\" + topic}\"\n }\n }\n },\n {\n \"create_subscription_to_topic\": {\n \"call\": \"googleapis.pubsub.v1.projects.subscriptions.create\",\n \"args\": {\n \"name\": \"${\\\"projects/\\\" + project_id + \\\"/subscriptions/\\\" + subscription}\",\n \"body\": {\n \"name\": \"${\\\"projects/\\\" + project_id + \\\"/subscriptions/\\\" + subscription}\",\n \"topic\": \"${\\\"projects/\\\" + project_id + \\\"/topics/\\\" + topic}\"\n }\n }\n }\n },\n {\n \"create_job\": {\n \"call\": \"googleapis.cloudscheduler.v1.projects.locations.jobs.create\",\n \"args\": {\n \"parent\": \"${\\\"projects/\\\" + project_id + \\\"/locations/\\\" + location_id}\",\n \"body\": {\n \"name\": \"${\\\"projects/\\\" + project_id + \\\"/locations/\\\" + location_id + \\\"/jobs/\\\" + job_id}\",\n \"description\": \"An example job created by Workflows to test the Cloud Scheduler connector.\",\n \"schedule\": \"* * * * *\",\n \"pubsubTarget\": {\n \"topicName\": \"${\\\"projects/\\\" + project_id + \\\"/topics/\\\" + topic}\",\n \"attributes\": {\n \"job\": \"finished!\"\n }\n }\n }\n }\n }\n },\n {\n \"sleep\": {\n \"call\": \"sys.sleep\",\n \"args\": {\n \"seconds\": 100\n }\n }\n },\n {\n \"pull_message\": {\n \"call\": \"googleapis.pubsub.v1.projects.subscriptions.pull\",\n \"args\": {\n \"subscription\": \"${\\\"projects/\\\" + project_id + \\\"/subscriptions/\\\" + subscription}\",\n \"body\": {\n \"maxMessages\": 1\n }\n }\n }\n },\n {\n \"delete_job\": {\n \"call\": \"googleapis.cloudscheduler.v1.projects.locations.jobs.delete\",\n \"args\": {\n \"name\": \"${\\\"projects/\\\" + project_id + \\\"/locations/\\\" + location_id + \\\"/jobs/\\\" + job_id}\"\n }\n }\n },\n {\n \"delete_subscription\": {\n \"call\": \"googleapis.pubsub.v1.projects.subscriptions.delete\",\n \"args\": {\n \"subscription\": \"${\\\"projects/\\\" + project_id + \\\"/subscriptions/\\\" + subscription}\"\n }\n }\n },\n {\n \"delete_topic\": {\n \"call\": \"googleapis.pubsub.v1.projects.topics.delete\",\n \"args\": {\n \"topic\": \"${\\\"projects/\\\" + project_id + \\\"/topics/\\\" + topic}\"\n }\n }\n },\n {\n \"the_end\": {\n \"return\": \"SUCCESS\"\n }\n }\n ]\n\nModule: googleapis.cloudscheduler.v1.projects.locations\n-------------------------------------------------------\n\nModule: googleapis.cloudscheduler.v1.projects.locations.jobs\n------------------------------------------------------------\n\nModule: googleapis.cloudscheduler.v1beta1.projects.locations\n------------------------------------------------------------\n\nModule: googleapis.cloudscheduler.v1beta1.projects.locations.jobs\n-----------------------------------------------------------------"]]