The Concurrent Processing Framework REST API allows client applications in Java, JavaScript or other programming languages to query the available business applications, create jobs and download the results of jobs on behalf of their users.
Most of the resources can return JSON or XML documents by appending the .json
or .xml
file format extension to the URI Templates before any query string parameters. JSON is the preferred
format due to it's well defined map, list and value structure. Some resources that
always return a specific data type will ignore the file format extension if specified.
The CPF REST API can also be accessed directly using a web browser by not specifying a file format extension. If a file format extension is not included in the request then the HTML user interface will be displayed instead of the resources described in this API. The HTML user interface allows full access to the CPF without any programming experience required. The HTML user interface will be slightly different from the responses described in this API.
Construct a new new job containing multiple requests to be processed by the business application.
The service parameters must be passed using the multipart/form-data encoding in the body of a HTTP POST request (e.g. a HTML form).
In addition to the standard parameters listed in the API each business application has additional job and request parameters. The Get Business Applications Multiple resource should be consulted to get the full list of supported parameters.
For structured input data business applications the requests are specified using either a single inputData file or a single inputDataUrl can be specified. The file must be in the file format specified by a single inputDataContentType. The contents of the file must contain one record for each request to be processed in the batch job. The fields of each record must contain the request parameters supported by the business application. The names of the parameters are case sensitive.
For opaque input data (e.g. JPEG image, ESRI Shapefile) the requests can be specified as one or more inputData files or one or more inputDataUrl parameters. It is not possible to mix inputData and inputDataUrl parameters in the same job. If all the requests have the same content type a single inputDataContentType can be specified. Otherwise an inputDataContentType must be specified for each inputData or inputDataUrl in the same order.
NOTE: The maximum size including all parameters and protocol overhead of a multi-part request is 20MB. Therefore inputDataUrl should be used instead of inputData where possible.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}/multiple
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource supports the following parameters. For HTTP get requests these must be specified using query string parameters. For HTTP POST requests these can be specified using query string, application/x-www-form-urlencoded parameters or multipart/form-data unless otherwise specified. Array values [] can be specified by including the parameter multiple times in the request.
Parameter | Type | Default | Required | Description |
---|
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | In a client application the resource will be returned in the body of the HTTP response in the requested format. See |
302 | In a web browser the user will be redirected to the |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Construct a new new job containing multiple requests to be processed by the business application.
The job and request parameters for the business application must be passed using the multipart/form-data encoding in the body of a HTTP POST request (e.g. a HTML form).
In addition to the standard parameters listed in the API each business application has additional job and request parameters. The Get Business Applications Single resource should be consulted to get the full list of supported parameters.
For structured input data business applications the request parameters are specified in the HTTP POST form.
For opaque input data (e.g. JPEG image, ESRI Shapefile) the requests can be specified as one inputData files or one inputDataUrl parameter. It is not possible to mix inputData and inputDataUrl parameters in the same job.
NOTE: The maximum size including all parameters and protocol overhead of a multi-part request is 20MB. Therefore inputDataUrl should be used instead of inputData where possible for opaque data.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}/single
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource supports the following parameters. For HTTP get requests these must be specified using query string parameters. For HTTP POST requests these can be specified using query string, application/x-www-form-urlencoded parameters or multipart/form-data unless otherwise specified. Array values [] can be specified by including the parameter multiple times in the request.
Parameter | Type | Default | Required | Description |
---|
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | In a client application the resource will be returned in the body of the HTTP response in the requested format. See |
302 | In a web browser the user will be redirected to the |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Cancel the user's job. This will mark the job as cancelled and remove all requests and results from the job. The job will be removed after a few days.
This service should be invoked after the results from the job are downloaded. If this method is not called the job will automatically be deleted 7 days after the result download was started.
This method can also be used to cancel a job before it was finished. If a job was submitted in error or no longer required use this method to cancel the job to help free resources on the system to process other jobs.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/jobs/{batchJobId}
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{batchJobId} | Long | The job identifier. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | OK If the job was deleted an empty response will be returned. |
404 | Not Found If the job does not exist, has been deleted, or was owned by another user. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Check that a user is authenticated. This can be used by JavaScript applications to force a login page to be displayed. Returns a map with authenticated=true if the user is authenticated. Response is undefined if the user is not authenticated as the authentication mechanism will not allow access to the resource.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/authenticated
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the list of links to the Get Business Applications Resources resource for each business application the user is authorized to access.
The method returns a Resource Description document. Each child resource supports following custom attributes.
Attribute | Description |
---|---|
businessApplicationName | The name of the business application. |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
The instant resource has the two modes described below, the specification mode and the
execute instant request mode. If the format
parameter is not included or the
specification
parameter equals true
then the specification mode
is enabled, otherwise the execute instant request mode is enabled.
Get the specification of the execute instant request mode of this service.
The method returns a Resource Description document with the following additional fields which are the parameters to the execute instant request mode..
Attribute | Description | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
description | The description of services offered by the business application. | ||||||||||||||
businessApplicationName | The name of the business application. | ||||||||||||||
businessApplicationTitle | The display title of the business application. | ||||||||||||||
businessApplicationDescription | The description of services offered by the business application. | ||||||||||||||
businessApplicationDescriptionUrl | A link to a web page describing more details about the business application. | ||||||||||||||
parameters | The array of parameters that can be passed to the service. Each parameter is an object containing the following fields.
|
||||||||||||||
inputDataContentTypes | The array of MIME media types of input data accepted by the business application. | ||||||||||||||
perRequestInputData | Boolean flag indicating that the business application accepts opaque data (true) or structured data (false). | ||||||||||||||
resultDataContentTypes | The array of MIME media types of result data generated by the business application. | ||||||||||||||
perRequestResultData | Boolean flag indicating that the business application returns opaque data (true) or structured data (false). |
Execute a single instant request using the business application with the results returned in the request.
The job and request parameters for the business application must be passed using the query string parameters in a HTTP get request or application/form-url-encoded, multipart/form-data encoding in the body of a HTTP POST request (e.g. a HTML form).
In addition to the standard parameters listed in the API each business application has additional job and request parameters. Invoke the specification mode of this resource should be consulted to get the full list of supported parameters.
NOTE: The instant resource does not support opaque input data.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}/instant
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource supports the following parameters. For HTTP get requests these must be specified using query string parameters. For HTTP POST requests these can be specified using query string, application/x-www-form-urlencoded parameters or multipart/form-data unless otherwise specified. Array values [] can be specified by including the parameter multiple times in the request.
Parameter | Type | Default | Required | Description |
---|
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
403 | If the user does not have permission for this resource on the business application. |
404 | If the business application does not exist, or is not enabled. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the list of links to the Get Jobs Info resource for each of the user's jobs for the business application.
The method returns a Resource Description document. Each child resource supports following custom attributes.
Attribute | Description |
---|---|
batchJobId | The unique identifier of the job. |
batchJobUrl | The URL to the Get Jobs Info resource without the file format extension. |
jobStatus | The current status of the job. |
creationTimestamp | The time when the job was created. |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}/jobs
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the specification of the Create Job With Multiple Requests service.
The method returns a Resource Description document with the following additional fields which are the parameters to the Create Job With Multiple Requests service..
Attribute | Description | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
description | The description of services offered by the business application. | ||||||||||||||
businessApplicationName | The name of the business application. | ||||||||||||||
businessApplicationTitle | The display title of the business application. | ||||||||||||||
businessApplicationDescription | The description of services offered by the business application. | ||||||||||||||
businessApplicationDescriptionUrl | A link to a web page describing more details about the business application. | ||||||||||||||
parameters | The array of parameters that can be passed to the service. Each parameter is an object containing the following fields.
|
||||||||||||||
inputDataContentTypes | The array of MIME media types of input data accepted by the business application. | ||||||||||||||
perRequestInputData | Boolean flag indicating that the business application accepts opaque data (true) or structured data (false). | ||||||||||||||
resultDataContentTypes | The array of MIME media types of result data generated by the business application. | ||||||||||||||
perRequestResultData | Boolean flag indicating that the business application returns opaque data (true) or structured data (false). |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}/multiple
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
403 | If the user does not have permission for this resource on the business application. |
404 | If the business application does not exist, or is not enabled. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the resources for a business application. The resource contains links to the instant, create single request job, and create multi request jobs resources.
The method returns a Resource Description document.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
403 | If the user does not have permission for this resource on the business application. |
404 | If the business application does not exist, or is not enabled. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the specification of the Create Job With Single Request service.
The method returns a Resource Description document with the following additional fields which are the parameters to the Create Job With Single Request service..
Attribute | Description | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
description | The description of services offered by the business application. | ||||||||||||||
businessApplicationName | The name of the business application. | ||||||||||||||
businessApplicationTitle | The display title of the business application. | ||||||||||||||
businessApplicationDescription | The description of services offered by the business application. | ||||||||||||||
businessApplicationDescriptionUrl | A link to a web page describing more details about the business application. | ||||||||||||||
parameters | The array of parameters that can be passed to the service. Each parameter is an object containing the following fields.
|
||||||||||||||
inputDataContentTypes | The array of MIME media types of input data accepted by the business application. | ||||||||||||||
perRequestInputData | Boolean flag indicating that the business application accepts opaque data (true) or structured data (false). | ||||||||||||||
resultDataContentTypes | The array of MIME media types of result data generated by the business application. | ||||||||||||||
perRequestResultData | Boolean flag indicating that the business application returns opaque data (true) or structured data (false). |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/apps/{businessApplicationName}/single
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{businessApplicationName} | String | The name of the business application. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
403 | If the user does not have permission for this resource on the business application. |
404 | If the business application does not exist, or is not enabled. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the list of links to the Get Jobs Info resource for each of the user's jobs.
The method returns a Resource Description document. Each child resource supports following custom attributes.
Attribute | Description |
---|---|
batchJobId | The unique identifier of the job. |
batchJobUrl | The URL to the Get Jobs Info resource without the file format extension. |
jobStatus | The current status of the job. |
creationTimestamp | The time when the job was created. |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/jobs
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the details of a job.
The method returns a BatchJob object with the following attributes.
Attribute | Description |
---|---|
id | The unique identifier of the job. |
businessApplicationName | The name of the business application. |
<parameter> | The the job parameters. |
resultSrid | The coordinate system code of the projection for the result geometry. |
resultNumAxis | The number of coordinate axis in the result geometry (e.g. 2 for 2D or 3 for 3D). |
resultScaleFactorXy | The scale factor to apply the x, y coordinates. The scale factor is 1 / minimum unit. For example if the minimum unit was 1mm (0.001) the scale factor is 1000 (1 / 0.001). |
resultScaleFactorZ | The scale factor to apply the z coordinate. The scale factor is 1 / minimum unit. For example if the minimum unit was 1mm (0.001) the scale factor is 1000 (1 / 0.001). |
resultDataContentType | The MIME type of the result data specified to be returned after running the request. |
jobStatus | The current status of the job. |
secondsToWaitForStatusCheck | The number of seconds to wait before checking the status again |
numSubmittedRequests | The number of requests submitted. |
numCompletedRequests | The number of requests that completed execution successfully. |
numFailedRequests | The number of requests that failed to execute. |
resultsUrl |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/jobs/{batchJobId}
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{batchJobId} | Long | The unique identifier of the job. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the contents of a user's job result file. The content type will be the content type requested in the job.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/jobs/{batchJobId}/results/{resultId}
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{batchJobId} | Long | The unique identifier of the job. |
{resultId} | int | The unique identifier of the result file. |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the list of links to the Get Jobs Result resource for each of the results for a user's job.
The method returns a Resource Description document. Each child resource supports following custom attributes.
Attribute | Description |
---|---|
batchJobResultType | The type of result file structuredResultData, opaqueResultData, errorResultData. |
batchJobResultContentType | The MIME type of the result file. |
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws/jobs/{batchJobId}/results
The URI templates support the following parameters which must be replaced with values as described below.
Parameter | Type | Description |
---|---|---|
{batchJobId} | Long |
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |
Get the root resource of the CPF web services. The resource contains links to the Get Jobs and Get Business Applications resources.
The method returns a Resource Description document.
The resource can be accessed using the following HTTP request methods.
The URI templates define the paths that can be appended to the base URL of the service to access this resource.
/ws
The resource will return one of the following status codes. The HTML error page may include an error message. The descriptions of the messages and the cause are described below.
HTTP Status Code | Description |
---|---|
200 | The resource will be returned in the body of the HTTP response in the requested format. |
500 | Internal Server Error This error indicates that there was an unexpected error on the server. This is sometimes temporary so try again after a few minutes. The problem could also be caused by bad input data so verify all input parameters and files. If the problem persists contact the support desk with exact details of the parameters you were using. |