# Nguồn chi tiết

Nguồn chi tiết là một thuộc tính của phiếu ghi nó chỉ rõ hơn nguồn phát sinh của phiếu ghi. Ví dụ: Từ một nhánh cụ thể  của số hotline, các comment của một bài viết trên trang Facebook hoặc phiếu ghi tạo qua API có các `ref_url` khác nhau ...

**Bảng thông tin của nguồn chi tiết**

<table><thead><tr><th width="88">STT</th><th width="218">Trường dữ liệu</th><th>Mô tả</th></tr></thead><tbody><tr><td>1</td><td>label</td><td>Tên nguồn</td></tr><tr><td>2</td><td>utm_campaign</td><td>UTM campaign</td></tr><tr><td>3</td><td>utm_source</td><td>UTM Source</td></tr><tr><td>4</td><td>utm_medium</td><td>UTM Medium</td></tr><tr><td>5</td><td>utm_term</td><td>UTM Term</td></tr><tr><td>6</td><td>utm_content</td><td>UTM Content</td></tr><tr><td>7</td><td>ad_id</td><td>Facebook ad Id</td></tr><tr><td>8</td><td>ad_campaign_id</td><td>Facebook ad Campaign Id</td></tr><tr><td>9</td><td>ad_name</td><td>Facebook ad name</td></tr><tr><td>10</td><td>ad_campaign_name</td><td>Facebook ad Campaign Name</td></tr><tr><td>11</td><td>adset_id</td><td>Adset Id </td></tr><tr><td>12</td><td>adset_name</td><td>Adset Name</td></tr></tbody></table>

## Lấy thông tin nguồn chi tiết qua API

Trong API  chi tiết phiếu ghi, tham số "`ticket_source_detail_id`" là ID của 1 nguồn chi tiết phát sinh ra phiếu ghi đó.  Để biết thông tin của nguồn này gọi theo API dưới đây

## Thông tin chi tiết của nguồn phiếu ghi

<mark style="color:blue;">`GET`</mark> `{{domain}}/api/v1/tickets/source/details/{{ticket_source_detail_id}}`

{{ticket\_source\_detail\_id}} là ID nguồn chi tiết lấy được từ API chi tiết ticket.&#x20;

#### Headers

| Name | Type   | Description                                                           |
| ---- | ------ | --------------------------------------------------------------------- |
| \*\* | String | [Thông tin xác thực chung ](/thong-tin-chung.md#phuong-thuc-xac-thuc) |

{% tabs %}
{% tab title="200: OK Kết quả điển hình" %}
{% tabs %}
{% tab title="Kết quả điển hình" %}

```json
{
    "status": true,
    "source_detail": {
        "label": "Web caresoft.vn",
        "utm_campaign": "SPRING_SALE_2023",
        "utm_source": "home_caresoft",
        "utm_medium": "banner",
        "utm_term": null,
        "utm_content": null,
        "ad_id": null,
        "ad_account_id": null,
        "ad_campaign_id": null,
        "adgroup_id": null,
        "ad_name": null,
        "ad_campaign_name": null,
        "ad_ref": null,
        "created_at": "2023-02-21 14:54:16",
        "updated_at": "2023-02-21 14:54:16",
        "channel": 6      
    },
    "code": "ok"
}
```

{% endtab %}

{% tab title="Mô tả" %}

{% endtab %}
{% endtabs %}

{% endtab %}
{% endtabs %}

<table><thead><tr><th width="88">STT</th><th width="218">Trường dữ liệu</th><th>Mô tả</th></tr></thead><tbody><tr><td>1</td><td>label</td><td>Tên nguồn</td></tr><tr><td>2</td><td>utm_campaign</td><td>UTM campaign</td></tr><tr><td>3</td><td>utm_source</td><td>UTM Source</td></tr><tr><td>4</td><td>utm_medium</td><td>UTM Medium</td></tr><tr><td>5</td><td>utm_term</td><td>UTM Term</td></tr><tr><td>6</td><td>utm_content</td><td>UTM Content</td></tr><tr><td>7</td><td>ad_id</td><td>Facebook ad Id</td></tr><tr><td>8</td><td>ad_campaign_id</td><td>Facebook ad Campaign Id</td></tr><tr><td>9</td><td>ad_name</td><td>Facebook ad name</td></tr><tr><td>10</td><td>ad_campaign_name</td><td>Facebook ad Campaign Name</td></tr><tr><td>11</td><td>adset_id</td><td>Adset Id </td></tr><tr><td>12</td><td>adset_name</td><td>Adset Name</td></tr></tbody></table>


---

# 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.caresoft.vn/danh-muc/restful-api-cua-caresoft/phieu-ghi/nguon-chi-tiet.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.
