メインコンテンツへスキップ
POST
/
job
/
create
Create Job
curl --request POST \
  --url https://cloud.cdata.com/api/job/create \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "jobType": "Caching",
  "intervalUnit": "Hour",
  "intervalValue": "1",
  "logVerbosity": "1",
  "enabled": "true",
  "params": {
    "timeCheckColumn": "",
    "autoTruncateStrings": "false",
    "sourceConnection": "36b2c04f-70f4-44a1-876a-29e42237ee63",
    "sourceName": "OData1",
    "sourceSchema": "OData",
    "sourceTable": "Categories"
  }
}
'
{
  "jobs": [
    {
      "id": "string",
      "name": "string",
      "enabled": true,
      "created": "2024-01-01T00:00:00Z",
      "lastModified": "2024-01-01T00:00:00Z",
      "nextRunTime": "2024-01-01T00:00:00Z",
      "intervalUnit": "Hour",
      "intervalValue": 1,
      "logVerbosity": 1,
      "lastRun": {
        "dateTime": "0001-01-01T00:00:00Z",
        "duration": 63894847975,
        "status": "JOB_QUEUED",
        "rowsAffected": 0,
        "nextRunTime": "0001-01-01T00:00:00Z"
      },
      "params": {
        "timeCheckColumn": "",
        "autoTruncateStrings": "false",
        "sourceConnection": "f6f3cfe6-72e2-4edb-914f-4409c01c1418",
        "sourceConnectionName": "MailChimp1",
        "sourceName": "MailChimp",
        "sourceSchema": "MailChimp",
        "sourceTable": "Conversations"
      }
    }
  ]
}

承認

Authorization
string
header
必須

JWT token authentication. Include the token in the Authorization header as 'Bearer '.

ボディ

application/json
jobType
string
必須

The type of job that the user wants to run (Caching or ScheduledQuery).

intervalUnit
string
必須

A string representing the time interval (Hour/Day/Week/Month).

intervalValue
integer<int32>
必須

An integer that represents how many of the selected frequency unit the job should wait before running again.

logVerbosity
integer<int32>
必須

An enum indicating the level of log verbosity (1-5).

params
object
必須

An object containing different job details depending on if the job is a cache job or a scheduled query.

enabled
boolean

A Boolean value indicating whether the job is enabled. The default value is true.

definedNextRun
string<date-time>

An optional DateTime value that can be used to set the initial start time for the job.

レスポンス

200 - application/json

OK

jobs
object[] | null