# Add student to class section

#### Add Student to Section

**Endpoint:**

```
PUT /v1/student/section/add
```

**Description:** This endpoint adds a student to a specified section within a school. It requires a JSON payload with the necessary details to add the student to the section.

**Headers:**

| Name          | Value                   |
| ------------- | ----------------------- |
| Content-Type  | application/json        |
| Authorization | Bearer \<access\_token> |

**Request Body:**

```json
{
    "section_id": "string",
    "student_id": "number",
    "school_slug": "string"
}
```

**Request Body Details:**

<table><thead><tr><th>Field</th><th width="139">Type</th><th>Description</th><th>Required</th></tr></thead><tbody><tr><td>section_id</td><td>string</td><td>The ID of the section</td><td>Yes</td></tr><tr><td>student_id</td><td>number</td><td>The ID of the student</td><td>Yes</td></tr><tr><td>school_slug</td><td>string</td><td>The slug of the school</td><td>Yes</td></tr></tbody></table>

**Response:**

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

```json
```

{% endtab %}

{% tab title="400" %}

```json
{
  "message": "string",
  "error": "string",
  "statusCode": "number"
}
```

{% endtab %}
{% endtabs %}


---

# 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://dugsi-docs.tiigsi.io/student-endpoints/add-student-to-class-section.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.
