# Decision Making

Welcome to AML Decision taking. In this, you can take a decision based on the details provided in the search menu.

You can look for any individual or company-related anti-money laundering compliances here, and specific action for the details will be provided.

The action is solely based on the clients wish.

#### Decision Making

`POST` `https://secctrl.tutelar.io/api/v1/aml/search/decision-make/:searchHistoryId`

| Name         | Value                 |
| ------------ | --------------------- |
| Content-Type | `multipart/form-data` |

#### Sample Response

201: OK

422: Unprocessable Entity

```json
{
   "success": true,
   "code": 201,
   "message": "Decisions created successfully",
   "data": {
       "decisionId": "decision_atanqCUkqz",
       "decisionAt": "2024-07-29T10:39:16.382Z",
       "decisionStatus": "true_match"
   }
}
```

```json
{
   "success": false,
   "code": 1001,
   "message": "Invalid Sanction",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Invalid Search History Id",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Decision Status field is missing",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Invalid data received from Decision Status",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Already Decision placed for this search id",
   "data": {}
}
{
    "success": false,
    "code": 1001,
    "message": "Please Enter any one sanctionId | adverseResultId",
    "data": {}
}
{
    "success": false,
    "code": 1001,
    "message": "Already Decision placed for this search id",
    "data": {}
}
```

#### Path param values

| Path parameter  | Type   | Is Mandatory | Description                                                                               |
| --------------- | ------ | ------------ | ----------------------------------------------------------------------------------------- |
| searchHistoryId | String | yes          | Search history Id will be generated for every Individual search made in the client panel. |

#### Post values are:

| Post Parameter | Type   | Is Mandatory | Description                                                                                                    |
| -------------- | ------ | ------------ | -------------------------------------------------------------------------------------------------------------- |
| decisionStatus | String | Yes          | Status of a Decision ( **"true\_match," "false\_positive,"** or **"no\_match" and "track"** )                  |
| sanctionId     | String | Yes          | sanctionId is unique Id. sanctionId required to make a decision if search search via aml alone search product. |
| remarks        | String | No           | Add remarks for decision purpose.                                                                              |
| file           | Binary | No           | Upload reference documents for decision.                                                                       |

#### Sample post data format

If make decision for aml alone search result

```json
{
   "decisionStatus": "true_match",
   "sanctionId": "SANCL_yZwvS457ed",
   "remarks": "Testing ",
   "file": "sample.pdf"
}
```

#### Success response :

If already decisions is not created for searchHistoryId.

```json
{
   "success": true,
   "code": 201,
   "message": "Decisions created successfully",
   "data": {
       "decisionId": "decision_atanqCUkqz",
       "decisionAt": "2024-07-29T10:39:16.382Z"
       "decisionStatus": "true_match"
   }
}
```

#### Failure response :

If already decisions created for searchHistoryId

````json
{
   "success": false,
   "code": 1001,
   "message": "Invalid Sanction",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Invalid Search History Id",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Decision Status field is missing",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Invalid data received from Decision Status",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Please provide valid searchData Mode",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Enter valid Search Data",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Invalid date formate on Search Date ",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Please enter Search History Id",
   "data": {}
}
{
   "success": false,
   "code": 1001,
   "message": "Already Decision placed for this search id",
   "data": {}
}

If already decisions created for searchHistoryId

```json
{
   "success": false,
   "code": 1001,
   "message": "Already Decision placed for this search id",
   "data": {}
}
````


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.v2.tutelar.io/decision-making-1.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
