catalyst-job-scheduling
Installation
SKILL.md
Catalyst Job Scheduling
Job Scheduling runs background work in three pieces: job pools (capacity containers), jobs (one execution each, submitted immediately via API/SDK/MCP), and crons (schedulers that submit jobs on a timetable). Every fact in this skill and its references is runtime-verified against a live Catalyst project (Aug 2026) unless marked otherwise.
Prerequisites
Before any operation, load references/job-scheduling-basics.md — it covers the five setup rules that cause most failures: job pool must exist first (no default), targets must be JOB-type functions, all time values in seconds, job_name limits, and function-vs-pool memory constraints.
How It Works
- Identify the target type: Job function (most common), Webhook (any HTTP URL), Circuit, or AppSail. Create/verify a matching-type job pool (Function pools size by
memoryMB; the others by concurrentnumber1–10). - One-off work → submit an immediate job (MCP
CatalystbyZoho_Create_Immediate_Jobor SDKjobScheduling().job().submitJob()). Recurring or delayed work → create a cron (CatalystbyZoho_Create_Cron_Jobor SDKcron().createCron()) choosing Periodic / OneTime / Calendar / CronExpression. Loadreferences/job-scheduling-basics.mdfor exact payloads for both paths. - Write the Job function handler
(jobRequest, context): initialize the SDK withcatalyst.initialize(context, { scope: 'admin' }), read inputs viajobRequest.getAllJobParams()(all values arrive as strings), and ALWAYS end withcontext.closeWithSuccess()orcloseWithFailure()— failure is what triggers the retry chain. - For retries, dynamic scheduling, webhook targets, or monitoring, load
references/job-scheduling-advanced.md— retry semantics (new job records linked byparent_job_id), firing behaviors (Periodic crons fire immediately on create AND update; past-dated OneTime fires instantly; OneTime auto-disables after firing), and observability traps (success/failure counters stay 0; dynamic crons are hidden from list APIs). - Verify by job records, not counters:
CatalystbyZoho_Get_Job_By_Idshowsjob_status(PENDING → RUNNING → SUCCESS | FAILURE),execution_time,dispatch_delay,response_code. Do not trust cronsuccess_count/failure_count— they stay 0.