Create, Run and Check Session Results

You can create, run and check the results of Sessions using the REST API. The following steps detail this process.

  1. Use the following PUT request to create the Session object in the location you define in {path}.

    The path must not already be in use by another Data Store or folder.

    PUT: http://<server>:<port>/1Integrate/rest/sessions/{path}

  2. Next, the {action} must be configured to one of 'play', 'pause', 'stop', or 'rewind' through a POST request.

    POST: http://<server>:<port>/1Integrate/rest/sessions/{path}?action={action}

    Rewind action also requires the taskIndex={index} for the task you want to rewind to.

    This request will immediately return and you will need to poll the following endpoint to check its new state.

  3. The next GET request must include the path to an object with a 'status': {status}. Additionally, you must poll this until the status is either 'Paused' or 'Finished'.

    GET: http://<server>:<port>/1Integrate/rest/results/{path}/status

  4. The following call returns the Session object that was originally created (assuming you have defined the correct {path}), including each task with their 'taskIndentifier'.

    GET: http://<server>:<port>/1Integrate/rest/sessions/{path}

    The 'taskIdentifier' field will be required to access the task results in the next step.

  5. Return the summary report for the entire task. This will also return the number of objects processed, errors encountered and total number of non-summary reports created.

    GET: /http://<server>:<port>/1Integrate/rest/results/{path}/task?taskIdentifier={taskIdentifier}

  6. Return the non-summary reports for the task.

    GET: http://<server>:<port>/1Integrate/rest/results/{path}/report?taskIdentifier={taskIdentifier}&start={start}&count={count}

    The GET request starts returning entries beginning at the entry number that the 'start’ is set to, and 'count determines the maximum number of entries returned from that point

    As reports are large objects, it is suggested that you only query ~1000 at a time, and use multiple calls to this endpoint to build up the full report list.

         Example: The GET request in step 5 returns the reportCount6570. This would mean that in the call for step 6 you could request start=0count=1000, which would return reports 0-999, followed by repeating the call with start=1000count=1000, which would return 1000-1999. From this point you could continue to call in blocks of 1000 until the return is less than 1000.