# Data Subject

## Get approver by purpose

<mark style="color:blue;">`GET`</mark> `https://api.domain.com/api/services/app/DataSubjects/GetApproverByPurpose`

This endpoint allows you to get list of identifier that approved on specific purpose.

#### Query Parameters

| Name      | Type   | Description                               |
| --------- | ------ | ----------------------------------------- |
| purposeId | string | ID ของวัตถุประสงค์ โดยมี format เป็น GUID |

#### Headers

| Name           | Type   | Description        |
| -------------- | ------ | ------------------ |
| Authentication | string | Bearer tokenของคุณ |

{% tabs %}
{% tab title="200 Successfully retrieved." %}

```
{
  "result": [],
  "targetUrl": null,
  "success": true,
  "error": null,
  "unAuthorizedRequest": false,
  "__abp": true
}
```

{% endtab %}
{% endtabs %}

## Check consent status by multi identifier and purpose

<mark style="color:green;">`POST`</mark> `https://api.domain.com/api/services/app/DataSubjects/CheckConsentStatus`

This endpoint allow you to get list of identifier that approved on specific identifiers and purpose

#### Request Body

| Name        | Type   | Description                               |
| ----------- | ------ | ----------------------------------------- |
| identifiers | array  | รายการ identifier ที่ต้องการ check status |
| purposeId   | string | ID ของวัตถุประสงค์ โดยมี format เป็น GUID |

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

```
{
  "result": [],
  "targetUrl": null,
  "success": true,
  "error": null,
  "unAuthorizedRequest": false,
  "__abp": true
}
```

{% endtab %}
{% endtabs %}

```
{
  "purposeId": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
  "identifiers": [
    "string"
  ]
}
```


---

# 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.reddot.co.th/consent-management-api/data-subject.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.
