# 요청

"# 요청

#### 요청 보내기

**호스트**

Web API v1 요청에 대한 호스트는 항상 `https://api.iafcertsearch.org/api/client/v1`입니다.

{% hint style="info" %}
모든 요청은 HTTPS를 통해 이루어져야 합니다. API는 HTTP를 지원하지 않습니다.
{% endhint %}

**인증 헤더**

[인증](https://github.com/QualityTrade/iaf-docs-api-developer-guide-ko/blob/main/api-integration/broken-reference/README.md)에서 설명한 대로 인증 헤더를 제공해야 합니다.

**HTTP 동사**

* `GET` 리소스나 리소스 그룹 검색
* `POST` 새 리소스 생성
* `PUT` 기존 리소스 업데이트
* `DELETE` 기존 리소스 삭제
* `OPTIONS` 특정 리소스에 대한 허용된 동사 보기

**Accept 헤더**

API는 JSON 응답을 제공합니다. 현재 accept 헤더는 필요하지 않지만, 앞으로 필요할 수도 있습니다. 설정되지 않은 경우 API는 `application/json`을 사용합니다.

```http
GET https://api.iafcertsearch.org/api/client/v1/endpoint HTTP/1.1
Accept: application/json
```

**데이터 배열**

`GET` 요청에서 데이터 배열을 보낼 때, URL에 매개변수를 여러 번 포함시켜야 합니다. 매개변수 이름에는 대괄호가 필요하지 않습니다.

```http
GET https://api.iafcertsearch.org/api/client/v1/endpoint?parameter=data1&parameter=data2 HTTP/1.1
```

#### 요청 형식 지정

**요청 본문**

`POST`나 `PUT`를 통해 리소스에 데이터를 제출할 때, 페이로드를 JSON으로 제출해야 합니다.

```http
POST https://api.iafcertsearch.org/api/client/v1/example/ HTTP/1.1
Content-Type: application/json
```

```json
{
  "name": "새 예제 이름"
}
```

**페이지네이션**

일부 `GET` 리소스는 일괄적으로 정보를 검색할 수 있도록 허용합니다. 해당되는 경우 리소스 설명에 쿼리 매개변수를 제공해 드리겠습니다.

여러 항목을 요청할 때, 요청 `limit`를 기본적으로 `20`으로 설정합니다. 필요할 때 `limit` 매개변수를 사용하여 다른 제한을 지정할 수 있습니다. 우리가 허용하는 `limit` 매개변수의 최대 값은 `100`입니다.

아래는 `limit=100`과 `offset=0` 매개변수에 의해 지정된 첫 번째 100개 레코드를 검색하는 API 요청 예시입니다.

다음 일괄 레코드를 검색하려면 offset 매개변수를 `1` 증가시키면 됩니다.

```http
GET https://api.iafcertsearch.org/api/client/v1/resource?limit=100&offset=0 HTTP/1.1
```

#### 성공적인 요청

| **동사** | **리소스 객체 반환**           |
| ------ | ----------------------- |
| GET    | 단일 리소스 객체나 리소스 객체 배열 반환 |
| PATCH  | 업데이트된 리소스 객체 반환         |
| PUT    | 업데이트된 리소스 객체 반환         |
| DELETE | 콘텐츠가 반환되지 않음            |
| POST   | 새로 생성된 리소스 객체 반환        |


---

# 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://support.iafcertsearch.org/api-developer-guide/api-ko/api-integration/requests.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.
