Steps to start a new scramble

Introduction

Before you start a new scramble, you should read the Getting Started With DMM API. In this page, you have the installation steps to start using the DMM API.

In all the requests you have to pass the header X-DMM-Token. This value is the one define in the section Define the REST API key from the Getting Started With DMM API page.

Create the connections

When you install the DMM API, it is automatically created the Runtime Connection. If you want to scramble data to this environment, you don't need to create any connection, otherwise you can create a Data Destination connection using the CreateConnection request.

Start the scramble

To start a new dcramble, you should use the StartExecution request.

The Type parameter is Scramble.

This request has the header X-DMM-Token-OTP and the value can be found in the environment where the scramble is to be executed, in the Authentication Token page.

You can find more information about the JSON configuration in the Start Execution scramble configuration page.

If this request finishes without any error, in the response you find the MainExecutionTrackerId. You will need this value to use the remaining requests related to this scramble.

Stop the scramble

You can use the StopExecution request to stop the scramble. The scramble process will be stopped and no more chunks will be scramble. The entities that already were scrambled will not be reverted!

Check the scramble status

You can use the GetExecutionStatus request to obtain some information about the scramble.

With this request you can get some reports (if you pass the parameter IncludeReports with value true), like number of records and when the scramble was started, and you can also get the execution log if you pass the parameter IncludeLogs with the value true.

Also, with the parameters LogRecords and LogPage you can have pagination in the logs (by default, you only will obtain the first 10 lines).

The log information will be return in the parameter Logs. This field is sent as a base64 string, so you need to do a base64 decode to obtain the log lines.

To learn more about this request response, you can follow this link.

Get the scramble final reports

You can use the GetExecutionOutputs request to obtain the final outputs when the scramble is finished.

This request only return data if the scramble already finishes (status InError or Complete). You can know the status with the GetExecutionStatus request, in the field Status.

With this request you can get some final reports (if you pass the parameter IncludeReports with value true), like number of records and when the scramble was started.

You can also get the execution final logs if you pass the parameter IncludeLogs with the value true. This field is sent as a base64 string, so you need to do a base64 decode to obtain the log zip file. After you do the base64 decode, you can save the file with the extension .zip. Inside this zip file, you can find one or more files with all the logs from the scramble.

To learn more about this request response, you can follow this link.