createJobExecution

Prev Next

Available in VPC

Run the task.

Request

This section describes the request format. The method and URI are as follows:

Method URI
POST /api/v1/jobs/{jobId}/executions

Request headers

For information about the request headers common to all Data Flow APIs, see Data Flow request headers.

Request path parameters

You can use the following path parameters with your request:

Field Type Required Description
jobId String Required Job ID

Request query parameters

You can use the following query parameters with your request:

Field Type Required Description
triggerId String Optional Trigger ID
workflowId String Optional Workflow ID

Request body

You can include the following data in the body of your request:

Field Type Required Description
jobCondition Object Optional Job execution option information
  • If omitted, use the execution settings saved in the job.
jobCondition.numWorker Integer Optional Number of workers
  • 2-10
  • Initial value for new jobs: 2
jobCondition.timeout Integer Optional Execution timeout (minute)
  • Time spent waiting for the results of a job when it is executed once
  • 1-1440
  • Initial value for new jobs: 360
jobCondition.nrn String Optional NAVER Cloud Platform resource identification value for job
jobCondition.scriptPath String Optional Job execution script storage path
jobCondition.logPath String Optional Job execution history storage path
jobCondition.parameters Object Optional Job parameters to be applied to this execution (SCRIPT jobs only)
  • Key-value type string map.
  • Only the values of keys declared in the job can be changed. Only the passed keys are overwritten; the remaining keys use the values stored in the job.

Request example

The request example is as follows:

The following is an example of running the job using the execution settings saved in the job.

curl --location --request POST 'https://dataflow.apigw.ntruss.com/api/v1/jobs/5Yns7J******/executions' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \
--data '{}'

The following is an example of changing the number of workers and some parameters for this run only.

curl --location --request POST 'https://dataflow.apigw.ntruss.com/api/v1/jobs/5Yns7J******/executions' \
--header 'x-ncp-apigw-timestamp: {Timestamp}' \
--header 'x-ncp-iam-access-key: {Access Key}' \
--header 'x-ncp-apigw-signature-v2: {API Gateway Signature}' \
--data '{
  "jobCondition": {
    "numWorker": 4,
    "parameters": {
      "target_date": "2025-03-23"
    }
  }
}'

Response

This section describes the response format.

Response body

The response body includes the following data:

Field Type Required Description
jobExecutionId String - Job execution ID
jobId String - Job ID
jobCondition Object - Job execution option information
jobCondition.numWorker Integer - Number of workers
  • 2-10
jobCondition.timeout Integer - Execution timeout (minute)
  • 1-1440
jobCondition.nrn String - NAVER Cloud Platform resource identification value for job
jobCondition.scriptPath String - Job execution script storage path
jobCondition.logPath String - Job execution history storage path
jobCondition.parameters Object - Job parameters applied to this execution
  • Key-value type string map
status String - Job execution status
  • READY | RUNNING | COMPLETED | FAILED | CANCELLING | CANCELLED | TIMEOUT
    • READY: Pending execution.
    • RUNNING: Running.
    • COMPLETED: Completed.
    • FAILED: Failed.
    • CANCELLING: Canceling.
    • CANCELLED: Canceled.
    • TIMEOUT: Execution time limit exceeded.
  • In the response to an execution request, the status is always READY.
startDate String - Job execution date and time
  • ISO 8601 format (including UTC+9)
createdDate String - Job creation date and time
  • ISO 8601 format (including UTC+9)
runningTime Integer - Job execution time (second)
  • In the execution request response, 0.
type String - Job type
  • JOB (default)

Response status codes

For information about the response status codes common to all Data Flow APIs, see Data Flow response status codes.

Response example

The response example is as follows:

{
  "jobExecutionId": "p4Y5Pk******",
  "jobId": "5Yns7J******",
  "jobCondition": {
    "numWorker": 4,
    "timeout": 360,
    "nrn": "nrn:PUB:IAM::*******:Role/********",
    "scriptPath": "dataflow-2706412-****/scripts/",
    "logPath": "dataflow-2706412-****/sparkHistoryLogs/",
    "parameters": {
      "target_date": "2025-03-23",
      "input_path": "aitems/sales/",
      "output_format": "parquet"
    }
  },
  "status": "READY",
  "startDate": "2025-03-23T09:00:12+09:00",
  "createdDate": "2025-03-23T09:00:12+09:00",
  "runningTime": 0,
  "type": "JOB"
}