Compute

Description: Computes a Rulex process.

URL/compute

Method: POST

Header: You must provide the authentication token in the header, using the following syntax:

{ Authorization : "Bearer" + " " + token }


Parameters

The Compute method uses the following parameters:

Name

Data Type

Mandatory

Default Value

Description

Name

Data Type

Mandatory

Default Value

Description

process

string

 

The name of the process you want to compute.

options.inmemory

boolean

true

If you want to compute the process "inmemory".

options.mode

string

"all"

The computation mode of the process.

options.tasks

array



The list of tasks to compute.

This option only applies when options.mode is different than "all"

options.storeSources

boolean

false

If you want to compute the process "inmemory" but saving the results of source (input) tasks.

This option only applies to inmemory computation

options.processVariables

object

null

The dictionary containing the process variables to write to the current process

options.inputs

object



The input data to feed inside the specific tasks.

options.inputs.task label.format

string

"cols"

The format of the data to feed as input.

options.inputs.task label.data (cols format)

object



An object representing the columns to feed as input.

There must be an array for each column.

options.inputs.task label.data (rows format)

array



An array representing the rows to feed as input.

There must be an object for each row.

options.outputs

object

 

The task to select to show in output.

options.outputs.task label

array

[ "*" ]

The list of attributes to show as output commands.


Syntax example

Data Params
{ process : process name, options : { inmemory : [true] | false, mode : ["all"] | null | "onwards"| "downon", tasks : task list | null, storeSources : [false] | true, processVariables : [null] | { ProcessVariable1 : "A", ProcessVariable2 : 1 } inputs : { task label : { format : ["cols"] | "rows", data (cols) : { Var_1 : ["A", "B", null, "Z"], Var_2 : [1, 2, 4, null], Var_3 : [0.1, 3.14, 4, 1.1] } data (rows) : [ { Var_1 : "A", Var_2 : 1, Var_3 : 0.1 }, { Var_1 : "B", Var_2 : 2, Var_3 : 3.14 }, { Var_1 : null, Var_2 : 4, Var_3 : 4 }, { Var_1 : "Z", Var_3 : 1.1, } ] }, }, outputs : { task label : ["*"] | attributes list } } }


Response Codes

Code

Result

Response

Code

Result

Response

Success

200

Success

{ data : required computation data }

Warnings

307

Temporary redirect

Client Errors

400

Bad request

 

404

Not found

 

 

Need to get in touch? https://www.rulex.ai/contact/ - Need a license renewal? https://rulex.atlassian.net/servicedesk/customer/user/login?destination=portals
© 2024 Rulex, Inc. All rights reserved.