Page cover image

Rule Flow Solver API (DEPRECATED)

Solve RuleFlow

Solves desired RuleFlow stored in decisionRules.

RuleFlow Solver

POST https://api.decisionrules.io/composition/solve/:ruleFlowId/:version

Path Parameters

Name
Type
Description

ruleFlowId

string

Unique RuleFlow ID that is the same to all versions. You can also use the rule alias.

version

integer

RuleFlow version. If the parameter is not filled in, the last published version will be used automatically.

Headers

Name
Type
Description

Authorization

string

Bearer

Content-Type

string

application/json

X-Strategy

string

STANDARD or ARRAY or FIRST_MATCH

X-Audit

string

Decides whether an audit of the solve should be created and saved. In case you want the audit to be created and saved, input "true".

X-Audit-Ttl

string

A number that dictates after how many days the audit will be deleted.

Request Body

Name
Type
Description

data

object

JSON object that describes the input json data

[
  {
    "loan": 30000,
    "tax": 1.15,
    "message": "eligible for the loan"
  }
]

If you're using the Regional Cloud version of DecisionRules, read more about API calls here.

See execution strategies to change solver output format.

Request example

URL
https://api.decisionrules.io/composition/solve/:ruleFlowId/:version

Headers:
Content-Type: application/json
Authorization: Bearer DOZpz-h6xnOrKGIINlYvkd9hn41pRR3oG6cqH

Note that you can use rule alias instead of rule ID to identify the rule flow. In that case, make sure that the rule alias is unique within the space, otherwise the request will fail.

This API Key. Generate your own here

{
    "data": {
        // INPUT OBJECT
    }
}

Example request

{
    "data": {
        "package": {
            "age": 30,
            "salary": 4000,
            "loanType": "household",
            "loan": 30000
        }
    }
}

Last updated

Was this helpful?