Add data to job
Add data (typically a document) to the job. The data is processed immediately by the workflow.
Use the startJob
request to signal that all data has been added to the job.
Note that the query parameter "url" must be used in conjunction with the "application/json" or "application/xml" content.
Path Parameters
- jobId string required
The job ID as returned by
createJob
.
Query Parameters
- url string
The HTTP(S) URL where the file can be downloaded.
If this parameter is used, the Content-Type must be application/json or application/xml and contain only the options.
- multipart/form-data
- application/json
- application/xml
Request Body required
options option[]
List of processing options
Options can either be set as job options in
createJob
or data specific options inaddData
. Data specific options are used to process the respective data and override job options of the same name. It is recommended to use job options whenever possible.Unless documented otherwise, each option must be set only once.
name string requiredOption name
The list of supported options depends on the
profile
used. Common names are:DOC.PASSWORD
: Password used for password protected files. This option can be added multiple times, where all passwords are tried. The list of passwords is also used to open embedded and/or attached files.
value string requiredThe option's value.
Note that the value must match the type required by the option. Otherwise workflow processing will abort with an error code
option
.- data binary required
The file/data to be appended to the job.
The
Content-Disposition
header must contain either thefilename
or thefilename*
parameter. It is recommended to set a filename with an extension. Alternatively the MIME type of the data is used to determine its type.The query parameter "url" is ignored if multipart/form-data content is used.
Request Body array required
- name string required
Option name
The list of supported options depends on the
profile
used. Common names are:DOC.PASSWORD
: Password used for password protected files. This option can be added multiple times, where all passwords are tried. The list of passwords is also used to open embedded and/or attached files.
- value string required
The option's value.
Note that the value must match the type required by the option. Otherwise workflow processing will abort with an error code
option
.
Request Body array required
- name string required
Option name
The list of supported options depends on the
profile
used. Common names are:DOC.PASSWORD
: Password used for password protected files. This option can be added multiple times, where all passwords are tried. The list of passwords is also used to open embedded and/or attached files.
- value string required
The option's value.
Note that the value must match the type required by the option. Otherwise workflow processing will abort with an error code
option
.
- 201
- 400
- 404
- 409
- 415
- 427
Successful response to the addData request
- application/json
- application/xml
- Schema
- Example (from schema)
Schema
- dataId string
Unique ID of the data.
This ID is returned by
addData
and can be used to associate events and messages to specific input data. Therefore it is highly recommended to log the data ID in the client log file.
{
"dataId": "string"
}
- Schema
- Example (from schema)
Schema
- dataId string
Unique ID of the data.
This ID is returned by
addData
and can be used to associate events and messages to specific input data. Therefore it is highly recommended to log the data ID in the client log file.
<dataId>string</dataId>
- Request could not be parsed
- The data is missing
- The data's filename is missing
- The options are not valid JSON/XML
- The file could not be downloaded from the provided URL.
- application/problem+json
- application/problem+xml
- Schema
- Example (from schema)
Schema
- type string
A URI reference that identifies the problem type. Note that this URI cannot be dereferenced.
- title string
A short, human-readable summary of the problem type.
- status string
The HTTP status code.
- detail string
A human-readable explanation specific to this occurrence of the problem.
{
"type": "string",
"title": "string",
"status": "string",
"detail": "string"
}
- Schema
- Example (from schema)
Schema
- type string
A URI reference that identifies the problem type. Note that this URI cannot be dereferenced.
- title string
A short, human-readable summary of the problem type.
- status string
The HTTP status code.
- detail string
A human-readable explanation specific to this occurrence of the problem.
<root>
<type>string</type>
<title>string</title>
<status>string</status>
<detail>string</detail>
</root>
The job with the specified ID could not be found.
- application/problem+json
- application/problem+xml
- Schema
- Example (from schema)
- Job Not Found Json
Schema
- type string
A URI reference that identifies the problem type. Note that this URI cannot be dereferenced.
- title string
A short, human-readable summary of the problem type.
- status string
The HTTP status code.
- detail string
A human-readable explanation specific to this occurrence of the problem.
{
"type": "string",
"title": "string",
"status": "string",
"detail": "string"
}
{
"type": "http://www.pdf-tools.com/service/rest/errors/jobNotFound",
"title": "Job not found.",
"detail": "The job with ID 'job_XYZ' could not be found",
"status": 404
}
- Schema
- Example (from schema)
- Job Not Found Json
Schema
- type string
A URI reference that identifies the problem type. Note that this URI cannot be dereferenced.
- title string
A short, human-readable summary of the problem type.
- status string
The HTTP status code.
- detail string
A human-readable explanation specific to this occurrence of the problem.
<root>
<type>string</type>
<title>string</title>
<status>string</status>
<detail>string</detail>
</root>
<problem xmlns="urn:ietf:rfc:7807">
<type>http://www.pdf-tools.com/service/rest/errors/jobNotFound</type>
<title>Job not found.</title>
<detail>The job with ID 'job_XYZ' could not be found</detail>
<status>404</status>
</problem>
The job has already been started or canceled.
- application/problem+json
- application/problem+xml
- Schema
- Example (from schema)
Schema
- type string
A URI reference that identifies the problem type. Note that this URI cannot be dereferenced.
- title string
A short, human-readable summary of the problem type.
- status string
The HTTP status code.
- detail string
A human-readable explanation specific to this occurrence of the problem.
{
"type": "string",
"title": "string",
"status": "string",
"detail": "string"
}
- Schema
- Example (from schema)
Schema
- type string
A URI reference that identifies the problem type. Note that this URI cannot be dereferenced.
- title string
A short, human-readable summary of the problem type.
- status string
The HTTP status code.
- detail string
A human-readable explanation specific to this occurrence of the problem.
<root>
<type>string</type>
<title>string</title>
<status>string</status>
<detail>string</detail>
</root>
- The content type is not multipart/form-data, application/json or application/xml
- The content type of the options field in the multipart/form-data content is not application/json
Problem with option data