Submit a Function Job by ID
Description
This API enables you to submit a job to a Job Pool that triggers a Job Function endpoint.
Request Details
Request URL
{api-domain}/baas/v1/project/{project_id}/job_scheduling/job
Request Headers
Authorization: Zoho-oauthtoken {oauth_token}
Content-Type: application/json
Optional Headers
CATALYST-ORG: {org_id}
Environment: Development
Scope
ZohoCatalyst.job.CREATE
Request JSON
You must send a JSON with its corresponding values as shown below.
{
"source_type": "API",
"job_config": {
"number_of_retries": "2",
"retry_interval": 10800
},
"job_name": "functionJob",
"jobpool_id": "10108000003823563",
"target_type": "Function",
"target_id": "10108000003823893",
"params": {
"param1": "value1"
}
}
You will feed this Request JSON to your Request Body, and you need to provide the value of:
Response Details
The JSON response returns the metadata of the submitted job. The response will also contain the details of the user who submitted the job.
curl -X POST \ ‘https://api.catalyst.zoho.com/baas/v1/project/10108000003823392/job_scheduling/job
-H “Authorization: Zoho-oauthtoken 1000.91016.2f57”
-H “Content-Type:application/json”
--data-raw ‘{“source_type”:“API”,“job_config”:{“number_of_retries”:“2”,“retry_interval”:10800},“job_name”:“functionJob”,“jobpool_id”:“10108000003823563”,“target_type”:“Function”,“target_id”:“10108000003823893”,“params”:{“param1”:“value1”}}’
{
"status": "success",
"data": {
"job_id": "10108000004194195",
"created_time": "Jun 05, 2024 04:51 PM",
"response_code": null,
"start_time": {},
"end_time": {},
"submitted_on": {
"startTimeToRedirectLogsPage": "05/06/2024 16:46",
"timeWithGivenTimezone": "Jun 05, 2024 04:51 PM IST",
"timeWithJobTimezone": "Jun 05, 2024 04:51 PM IST"
},
"job_status": "PENDING",
"capacity": {
"memory": "512"
},
"job_meta_details": {
"id": "10108000004194196",
"url": "",
"job_name": "functionJob",
"job_config": {
"number_of_retries": 2,
"retry_interval": 10800
},
"target_type": "Function",
"target_details": {
"id": "10108000003823893",
"target_name": "target_function_fetch"
},
"source_type": "API",
"source_details": {
"source_name": "API"
},
"jobpool_id": "10108000003823563",
"jobpool_details": {
"type": "Function",
"name": "VendorReminder",
"created_by": {
"zuid": "77941453",
"is_confirmed": false,
"email_id": "emmy@zylker.com",
"first_name": "Amelia Burrows",
"last_name": "",
"user_type": "Admin",
"user_id": "10108000000009004"
},
"created_time": "May 28, 2024 04:44 PM",
"modified_by": {
"zuid": "77941453",
"is_confirmed": false,
"email_id": "emmy@zylker.com",
"first_name": "Amelia Burrows",
"last_name": "",
"user_type": "Admin",
"user_id": "10108000000009004"
},
"modified_time": "May 28, 2024 04:44 PM",
"project_details": {
"project_name": "ZylkerShipments",
"id": "10108000003823392",
"project_type": "Live"
},
"id": "10108000003823563"
},
"headers": {},
"params": {
"param1": "value1"
}
},
"retried_count": null,
"parent_job_id": "10108000004194195",
"execution_time": null
}
}
Yes
No
Send your feedback to us