# Для сделок

## Типы

## Список значений справочника типы сделок

<mark style="color:blue;">`GET`</mark> `https://do.myfreshcloud.com/directory/32`

#### Path Parameters

| Name                                  | Type | Description     |
| ------------------------------------- | ---- | --------------- |
| /32<mark style="color:red;">\*</mark> | Int  | Код справочника |

#### Headers

| Name                                            | Type   | Description               |
| ----------------------------------------------- | ------ | ------------------------- |
| Authorization<mark style="color:red;">\*</mark> | String | Bearer XXXXX.XXXXXX.XXXXX |
| Content-Type                                    | String | application/json          |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
  "status": "success",
  "error": "",
  "code": null,
  "rows": 0,
  "pages": 0,
  "page": 0,
  "value": "[
               {
                "ID": 1,
                "NAME": "Some value"
                }
            ]"
}
```

{% endtab %}

{% tab title="401: Unauthorized " %}

```javascript
{
    // Response
}
```

{% endtab %}
{% endtabs %}

## Columns

| Имя  | Описание      |
| ---- | ------------- |
| ID   | Идентификатор |
| NAME | Значение      |

## Статусы

{% hint style="info" %}
**Обратите внимание:**  у разных типов сделок свои статусы, это необходимо учесть при добавлении или изменении сделки. ⚡️**ID\_TYPE\_OF\_DEAL** указывает на код типа сделки к которому отнесен статус. ⚡️**IS\_FINAL** колонка указывает являться ли статус закрывающим для сделки, закрывающие статусы являются общими для всех типов сделок.
{% endhint %}

## Список значений справочника статусы сделок

<mark style="color:blue;">`GET`</mark> `https://do.myfreshcloud.com/directory/31`

#### Path Parameters

| Name                                  | Type | Description     |
| ------------------------------------- | ---- | --------------- |
| /31<mark style="color:red;">\*</mark> | Int  | Код справочника |

#### Headers

| Name          | Type   | Description               |
| ------------- | ------ | ------------------------- |
| Authorization | String | Bearer XXXXX.XXXXXX.XXXXX |
| Content-Type  | String | application/json          |

{% tabs %}
{% tab title="200: OK " %}

```javascript
{
  "status": "success",
  "error": "",
  "code": null,
  "rows": 0,
  "pages": 0,
  "page": 0,
  "value": "[
               {
                "ID": 1,
                "NAME": "Some value",
                "ID_TYPE_OF_DEAL" : 1,
                "IS_FINAL" : false
                }
            ]"
}
```

{% endtab %}

{% tab title="401: Unauthorized " %}

```javascript
{
    // Response
}
```

{% endtab %}
{% endtabs %}

## Columns

| Имя                    | Описание                                                                                                                   |
| ---------------------- | -------------------------------------------------------------------------------------------------------------------------- |
| **ID**                 | Идентификатор                                                                                                              |
| **NAME**               | Значение                                                                                                                   |
| **ID\_TYPE\_OF\_DEAL** | Статус отнесен к типу сделки                                                                                               |
| **IS\_FINAL**          | <p>Флаг указывает, статус является закрывающем для сделки или нет <br><strong>true</strong> или <strong>false</strong></p> |


---

# 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://apidoc.myfreshcloud.com/reference/directory/directories-deal.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.
