POST v1/ExecuteJobAsync

Executes a Job in asynchronous mode. The response will be returned immediately. You can configure a webhook to be notififed upon completion, or you can check the results via the Results API.

Request Information

URI Parameters

None.

Body Parameters

Required parameters to begin job execution.

execJobAsyncRequest
NameDescriptionTypeAdditional information
runID

GUID-formatted ID supplied by the user.

string

Required

Max length: 36

projectID

ID of the project which contains the job you wish to run.

string

Required

Max length: 36

jobID

ID of the job within the specified project to run.

string

Required

Max length: 36

chainJobs

Execute all jobs in the chain? Default: false

boolean

None.

loggingLevel

Defines the verbosity of the log returned. Default: 0 0=None, 1=Low, 2=Medium, 3=High

integer

None.

argument

Any string value you wish to pass into your job's execution. This is commonly used for filtering which rows to run, such as passing in the ID of a record to process. It is available within your job as the User-Defined variable "Job Argument" (@@VAR:JobArgument@@).

string

None.

beginAtRow

Tells the job to skip ahead to this row and start processing. Default: 1

string

None.

endAfterRow

Job execution will end after processing this row. Default: Process to end of all rows.

string

None.

threadCount

Number of threads to spawn for processing data into destination. Default: 1

string

None.

webHookURL

The URL for the results to be POST'd to once the execution is complete. Data will be JSON in the execJobResponse format (See response type of the ExecuteJob API).

string

None.

Request Formats

application/json, text/json

Sample:
{
  "runID": "sample string 1",
  "projectID": "sample string 2",
  "jobID": "sample string 3",
  "chainJobs": true,
  "loggingLevel": 5,
  "argument": "sample string 6",
  "beginAtRow": "sample string 7",
  "endAfterRow": "sample string 8",
  "threadCount": "sample string 9",
  "webHookURL": "sample string 10"
}

application/xml, text/xml

Sample:
<execJobAsyncRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/StarfishAPI.Controllers">
  <argument>sample string 6</argument>
  <beginAtRow>sample string 7</beginAtRow>
  <chainJobs>true</chainJobs>
  <endAfterRow>sample string 8</endAfterRow>
  <jobID>sample string 3</jobID>
  <loggingLevel>5</loggingLevel>
  <projectID>sample string 2</projectID>
  <runID>sample string 1</runID>
  <threadCount>sample string 9</threadCount>
  <webHookURL>sample string 10</webHookURL>
</execJobAsyncRequest>

application/x-www-form-urlencoded

Sample:

Sample not available.

Response Information

Resource Description

execJobAsyncResponse
NameDescriptionTypeAdditional information
runID

GUID-formatted ID which was supplied by the user at the start

string

None.

started

Result status after run. Typically "Started" or "Failed".

boolean

None.

error

Error message that may have occurred while trying to start the job.

string

None.

Response Formats

application/json, text/json

Sample:
{
  "runID": "sample string 1",
  "started": true,
  "error": "sample string 3"
}

application/xml, text/xml

Sample:
<execJobAsyncResponse xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/StarfishAPI.Controllers">
  <error>sample string 3</error>
  <runID>sample string 1</runID>
  <started>true</started>
</execJobAsyncResponse>