# 인증창 없이 연동

원문: https://developers.bootpay.ai/api/identity/no-window

> 인증창 없이 REST API로 SMS·PASS 본인인증을 직접 연동하는 방법 (REST API 본인인증)

부트페이 인증창 없이 가맹점이 직접 만든 화면에서 본인인증을 합니다(REST API 본인인증). 서버가 사용자 정보로 인증을 요청하면 사용자 휴대폰으로 인증번호(OTP)가 전송되거나 PASS 앱 푸시가 가고, 사용자가 입력한 번호로 승인합니다. 모든 호출은 서버에서 [Basic Auth](https://developers.bootpay.ai/api/common/authentication)로 인증합니다.

## 전체 흐름

:::canvas-sequence
{
  "participants": [
    { "id": "user", "label": "사용자" },
    { "id": "fe", "label": "내 화면" },
    { "id": "be", "label": "내 서버" },
    { "id": "bp", "label": "Bootpay/PG" }
  ],
  "messages": [
    { "from": "user", "to": "fe", "label": "이름·생년월일·통신사·번호 입력", "type": "solid" },
    { "from": "fe", "to": "be", "label": "인증 요청", "type": "solid" },
    { "from": "be", "to": "bp", "label": "POST /v2/request/authentication", "type": "solid" },
    { "from": "bp", "to": "user", "label": "SMS 인증번호 발송", "type": "solid" },
    { "from": "bp", "to": "be", "label": "receipt_id", "type": "dashed" },
    { "from": "user", "to": "fe", "label": "인증번호 입력", "type": "solid" },
    { "from": "fe", "to": "be", "label": "OTP 전달", "type": "solid" },
    { "from": "be", "to": "bp", "label": "POST /v2/authenticate/confirm", "type": "solid" },
    { "from": "bp", "to": "be", "label": "status 12 + authenticate_data", "type": "dashed" },
    { "from": "be", "to": "be", "label": "검증·필요한 값만 저장", "type": "solid" }
  ]
}
:::

| 단계 | API | 설명 |
| --- | --- | --- |
| ① 인증 요청 | `POST /v2/request/authentication` | 이름·생년월일·통신사·휴대폰 번호로 인증 요청. SMS 인증번호 발송 또는 PASS 앱 푸시 |
| ② 인증 승인 | `POST /v2/authenticate/confirm` | 사용자가 입력한 OTP로 인증 승인 |
| ③ 인증번호 재전송 | `POST /v2/authenticate/realarm` | (선택) 인증번호를 받지 못한 경우 SMS 재전송 |
| ④ 인증 정보 조회 | `GET /v2/certificate/{receipt_id}` | 승인 응답 외에 다시 확인이 필요할 때([인증 정보 조회·검증](https://developers.bootpay.ai/api/identity/verify)) |

## ① 인증 요청

::: endpoint
method: POST
url: https://api.bootpay.co.kr/v2/request/authentication
auth: Basic Auth
:::

::: parameters

| 파라미터 | 타입 | 필수 | 설명 |
|---------|------|------|------|
| authentication_id | String | Y | 가맹점 고유 인증번호. 유니크한 값으로 생성하고 DB에 저장합니다 |
| pg | String | Y | 인증 PG. 인증창 없는 REST 방식은 `다날`만 지원하며, 다날 계약에 REST 본인인증이 열려 있어야 합니다. 다른 PG를 보내면 `AUTH_CONFIRM_METHOD_NOT_FOUND`(2406, HTTP 404)가 반환됩니다 |
| method | String | Y | `본인인증` |
| username | String | Y | 사용자 이름 |
| identity_no | String | Y | 생년월일 6자리(`YYMMDD`) + 주민등록번호 뒤 첫 1자리 = 항상 7자리 (예: `9001011`). 7자 미만이면 PG 호출 전에 거부됩니다 |
| carrier | String | Y | 통신사. `SKT` / `KT` / `LGT` / `SKT_MVNO` / `KT_MVNO` / `LGT_MVNO` 6개 값만 허용됩니다 (`_MVNO`는 알뜰폰) |
| phone | String | Y | 휴대폰 번호 (하이픈 없이) |
| client_ip | String | N | 인증을 요청한 사용자의 IP. 생략하면 API를 호출한 서버의 IP가 대신 쓰입니다 |
| order_name | String | Y | 인증 요청명 (예: "회원가입 본인인증") |
| authenticate_type | String | N | `sms`(문자 인증) 또는 `pass`(PASS 앱 인증). 미입력 시 `sms`. 두 값 외에는 요청이 거부됩니다 |
| site_url | String | N | 본인인증을 진행하는 사이트 URL 또는 앱 이름. 부트페이가 검사하지는 않지만 다날 인증창 표기값(`CPTITLE`)으로 사용됩니다 |
| user | Object | N | 추가 사용자 정보. 최상위 `username` · `phone` 을 생략하면 `user.username` · `user.phone` 이 대신 쓰입니다 |
| extra | Object | N | 추가 옵션. `extra.timeout` 은 본인인증에 적용되지 않습니다(아래) |
| metadata | Object | N | 전달할 추가 데이터. 결과에 그대로 반환됩니다 |

:::

::: tip client_ip는 최종 사용자 IP를 넘깁니다
`client_ip`를 생략하면 API를 호출한 서버의 IP가 대신 쓰입니다. 이상 거래 판단에 사용되는 값이므로 사용자 브라우저·앱의 IP를 넘깁니다. 프록시·로드밸런서 뒤에 있다면 `X-Forwarded-For` 헤더의 첫 번째 값을 사용합니다.
:::

::: code-group sync=backend

```javascript [Node.js]
import { Bootpay } from '@bootpay/backend-js'

Bootpay.setConfiguration({
    client_key: '[ Client Key ]',
    secret_key: '[ Secret Key ]'
})

// 사용자 휴대폰으로 인증번호가 전송된다.
const requested = await Bootpay.requestAuthentication({
    authentication_id: 'auth_' + Date.now(),
    pg: '다날',
    method: '본인인증',
    order_name: '회원가입 본인인증',
    authenticate_type: 'sms',
    username: '홍길동',
    identity_no: '9001011',   // 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
    carrier: 'SKT',
    phone: '01012345678',
    client_ip: req.headers['x-forwarded-for']?.split(',')[0] ?? req.socket.remoteAddress
})

// receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다.
console.log(requested.receipt_id)
```

```python [Python]
import time
from bootpay_backend import BootpayBackend

bootpay = BootpayBackend(client_key='[ Client Key ]', secret_key='[ Secret Key ]')

# 사용자 휴대폰으로 인증번호가 전송된다.
requested = bootpay.request_authentication(
    authentication_id=f'auth_{int(time.time())}',
    pg='다날',
    method='본인인증',
    order_name='회원가입 본인인증',
    authenticate_type='sms',
    username='홍길동',
    identity_no='9001011',  # 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
    carrier='SKT',
    phone='01012345678',
    client_ip=request.headers.get('X-Forwarded-For', request.remote_addr).split(',')[0]
)

# receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다.
print(requested.get('receipt_id'))
```

```php [PHP]
BootpayApi::setClientKeyConfiguration('[ Client Key ]', '[ Secret Key ]');

// 사용자 휴대폰으로 인증번호가 전송된다.
$requested = BootpayApi::requestAuthentication([
    'authentication_id' => 'auth_' . time(),
    'pg' => '다날',
    'method' => '본인인증',
    'order_name' => '회원가입 본인인증',
    'authenticate_type' => 'sms',
    'username' => '홍길동',
    'identity_no' => '9001011',  // 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
    'carrier' => 'SKT',
    'phone' => '01012345678',
    'client_ip' => $_SERVER['HTTP_X_FORWARDED_FOR'] ?? $_SERVER['REMOTE_ADDR']
]);

// receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다.
echo $requested->receipt_id;
```

```java [Java]
import java.util.HashMap;
import kr.co.bootpay.pg.Bootpay;
import kr.co.bootpay.pg.model.request.Authentication;

Bootpay bootpay = Bootpay.withClientKey("[ Client Key ]", "[ Secret Key ]");

Authentication auth = new Authentication();
auth.authenticationId = "auth_" + System.currentTimeMillis();
auth.pg = "다날";
auth.method = "본인인증";
auth.orderName = "회원가입 본인인증";
auth.authenticateType = "sms";
auth.username = "홍길동";
auth.identityNo = "9001011"; // 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
auth.carrier = "SKT";
auth.phone = "01012345678";
auth.clientIp = clientIp;

// 사용자 휴대폰으로 인증번호가 전송된다.
HashMap<String, Object> requested = bootpay.requestAuthentication(auth);

// receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다.
String receiptId = (String) requested.get("receipt_id");
```

```ruby [Ruby]
bootpay = Bootpay::RestClient.new(client_key: '[ Client Key ]', secret_key: '[ Secret Key ]')

# 사용자 휴대폰으로 인증번호가 전송된다.
requested = bootpay.request_authentication(
  authentication_id: "auth_#{Time.now.to_i}",
  pg: '다날',
  method: '본인인증',
  order_name: '회원가입 본인인증',
  authenticate_type: 'sms',
  username: '홍길동',
  identity_no: '9001011',  # 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
  carrier: 'SKT',
  phone: '01012345678',
  site_url: 'https://example.com',  # gem 에서는 필수 키워드 인자
  client_ip: request.env['HTTP_X_FORWARDED_FOR'] || request.ip
)

# receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다. 응답 키는 심볼이다.
receipt_id = requested.data[:receipt_id]
```

```go [Go]
api := bootpay.NewAPIWithClientKey("[ Client Key ]", "[ Secret Key ]", nil, "")

authData := bootpay.Authentication{
	AuthenticationId: fmt.Sprintf("auth_%d", time.Now().UnixMilli()),
	Pg:               "다날",
	Method:           "본인인증",
	OrderName:        "회원가입 본인인증",
	AuthenticateType: "sms",
	Username:         "홍길동",
	IdentityNo:       "9001011", // 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
	Carrier:          "SKT",
	Phone:            "01012345678",
	ClientIp:         clientIp,
}

// 사용자 휴대폰으로 인증번호가 전송된다.
requested, err := api.RequestAuthentication(authData)
if err != nil {
	return err
}

// 요청 실패는 err 가 아니라 error_code 가 담긴 응답으로 온다 (err 는 네트워크 오류일 때만).
receiptId, ok := requested["receipt_id"].(string)
if !ok {
	return fmt.Errorf("본인인증 요청 실패: %v", requested["error_code"])
}
// receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다.
```

```csharp [.NET]
using Bootpay;
using Bootpay.models;
using Newtonsoft.Json;

var api = BootpayApi.WithClientKey("[ Client Key ]", "[ Secret Key ]");

var auth = new Authentication
{
    authenticationId = $"auth_{DateTimeOffset.Now.ToUnixTimeMilliseconds()}",
    pg = "다날",
    method = "본인인증",
    orderName = "회원가입 본인인증",
    authenticateType = "sms",
    username = "홍길동",
    identityNo = "9001011", // 생년월일 6자리 + 주민등록번호 뒤 첫 1자리 = 7자리
    carrier = "SKT",
    phone = "01012345678",
    clientIp = clientIp
};

// 사용자 휴대폰으로 인증번호가 전송된다.
var response = await api.RequestAuthentication(auth);
var requested = JsonConvert.DeserializeObject<Dictionary<string, object>>(
    await response.Content.ReadAsStringAsync()
);

// receipt_id를 세션·DB에 보관했다가 승인 단계에서 사용한다.
var receiptId = requested["receipt_id"].ToString();
```

:::

::: info extra.timeout은 본인인증에 적용되지 않습니다
`extra.timeout`은 결제창 만료 시각을 저장할 때만 쓰이고, 인증 승인·재전송·조회 어디에서도 검사하지 않습니다. 조회 제한은 승인 완료 후 30분 고정입니다.
:::

### 응답 예시

```json
{
  "receipt_id": "636375501fc19203724b3ad8",
  "authentication_id": "1667462479",
  "metadata": {},
  "pg": "다날",
  "method": "인증",
  "method_symbol": "auth",
  "method_origin": "인증",
  "method_origin_symbol": "auth",
  "requested_at": "2026-04-03T17:01:20+09:00",
  "status": 51,
  "authenticate_data": {
    "tid": "202211031701204002337011",
    "number_of_realarms": 0
  }
}
```

`status: 51`은 SMS/PASS 발송이 끝나고 OTP 승인을 기다리는 상태입니다. `receipt_id`를 보관했다가 승인 단계에서 사용합니다.
`51`은 상태 한글 라벨이 정의돼 있지 않아 `status_locale` 키 자체가 응답에서 빠집니다.

## ② 인증 승인

사용자가 화면에 입력한 인증번호(OTP)를 서버로 받아 승인합니다. 응답의 `status`가 `12`면 인증 완료입니다.

::: endpoint
method: POST
url: https://api.bootpay.co.kr/v2/authenticate/confirm
auth: Basic Auth
:::

::: parameters

| 파라미터 | 타입 | 필수 | 설명 |
|---------|------|------|------|
| receipt_id | String | Y | ① 인증 요청 응답으로 받은 값 |
| otp | String | N | 사용자가 입력한 6자리 인증번호. `sms` 방식에서는 필수이고, PASS 앱 방식은 빈 값(`null`)입니다 |

:::

::: code-group sync=backend

```javascript [Node.js]
const confirmed = await Bootpay.confirmAuthentication(receipt_id, otp)

// status 12(본인인증완료)일 때만 인증 완료로 처리한다.
if (confirmed.status !== 12) {
    throw new Error('본인인증이 완료되지 않았습니다.')
}

const data = confirmed.authenticate_data
await saveVerifiedUser({
    name: data.name,
    birth: data.birth,
    ci: data.unique,   // unique = CI(연계정보). 기관 공통 식별값
    di: data.di        // di = DI(중복가입 확인정보). 가맹점별 식별값
})
```

```python [Python]
confirmed = bootpay.confirm_authentication(receipt_id=receipt_id, otp=otp)

# status 12(본인인증완료)일 때만 인증 완료로 처리한다.
if confirmed.get('status') != 12:
    raise Exception('본인인증이 완료되지 않았습니다.')

# unique = CI(연계정보, 기관 공통), di = DI(중복가입 확인정보, 가맹점별)
data = confirmed.get('authenticate_data')
save_verified_user(
    name=data.get('name'),
    birth=data.get('birth'),
    ci=data.get('unique'),
    di=data.get('di')
)
```

```php [PHP]
$confirmed = BootpayApi::confirmAuthentication($receiptId, $otp);

// status 12(본인인증완료)일 때만 인증 완료로 처리한다.
if ($confirmed->status !== 12) {
    throw new Exception('본인인증이 완료되지 않았습니다.');
}

// unique = CI(연계정보, 기관 공통), di = DI(중복가입 확인정보, 가맹점별)
$data = $confirmed->authenticate_data;
saveVerifiedUser($data->name, $data->birth, $data->unique, $data->di);
```

```java [Java]
HashMap<String, Object> confirmed = bootpay.confirmAuthentication(receiptId, otp);

// status 12(본인인증완료)일 때만 인증 완료로 처리한다.
if (((Number) confirmed.get("status")).intValue() != 12) {
    throw new IllegalStateException("본인인증이 완료되지 않았습니다.");
}

// unique = CI(연계정보, 기관 공통), di = DI(중복가입 확인정보, 가맹점별)
@SuppressWarnings("unchecked")
Map<String, Object> data = (Map<String, Object>) confirmed.get("authenticate_data");
saveVerifiedUser(data.get("name"), data.get("birth"), data.get("unique"), data.get("di"));
```

```ruby [Ruby]
confirmed = bootpay.confirm_authentication(receipt_id: receipt_id, otp: otp).data

# status 12(본인인증완료)일 때만 인증 완료로 처리한다.
raise '본인인증이 완료되지 않았습니다.' if confirmed[:status] != 12

# unique = CI(연계정보, 기관 공통), di = DI(중복가입 확인정보, 가맹점별)
data = confirmed[:authenticate_data]
save_verified_user(name: data[:name], birth: data[:birth], ci: data[:unique], di: data[:di])
```

```go [Go]
confirmed, err := api.ConfirmAuthentication(bootpay.AuthenticationParams{
	ReceiptId: receiptId,
	Otp:       otp,
})
if err != nil {
	return err
}

// status 12(본인인증완료)일 때만 인증 완료로 처리한다. 실패 응답에는 status 가 없으므로 comma-ok 로 읽는다.
status, _ := confirmed["status"].(float64)
if int(status) != 12 {
	return errors.New("본인인증이 완료되지 않았습니다.")
}

// unique = CI(연계정보, 기관 공통), di = DI(중복가입 확인정보, 가맹점별)
data := confirmed["authenticate_data"].(map[string]interface{})
saveVerifiedUser(data["name"], data["birth"], data["unique"], data["di"])
```

```csharp [.NET]
var confirmResponse = await api.ConfirmAuthentication(new AuthenticationParams
{
    receiptId = receiptId,
    otp = otp
});
var confirmed = JsonConvert.DeserializeObject<Dictionary<string, object>>(
    await confirmResponse.Content.ReadAsStringAsync()
);

// status 12(본인인증완료)일 때만 인증 완료로 처리한다.
if (Convert.ToInt32(confirmed["status"]) != 12)
{
    throw new InvalidOperationException("본인인증이 완료되지 않았습니다.");
}

// unique = CI(연계정보, 기관 공통), di = DI(중복가입 확인정보, 가맹점별)
var data = (JObject)confirmed["authenticate_data"];
SaveVerifiedUser(data["name"], data["birth"], data["unique"], data["di"]);
```

:::

### 응답 예시

```json
{
  "receipt_id": "624d2e531fc19202e4746f40",
  "authentication_id": "1649225299700",
  "gateway_url": "https://gw.bootpay.co.kr",
  "metadata": {},
  "pg": "다날",
  "method": "인증",
  "method_symbol": "auth",
  "method_origin": "인증",
  "method_origin_symbol": "auth",
  "authenticated_at": "2026-04-06T15:08:42+09:00",
  "requested_at": "2026-04-06T15:07:58+09:00",
  "status_locale": "본인인증완료",
  "status": 12,
  "authenticate_data": {
    "phone": "01012345678",
    "name": "홍길동",
    "birth": "19911212",
    "gender": 0,
    "foreigner": "0",
    "carrier": "SKT",
    "unique": "[ CI 값 ]",
    "di": "[ DI 값 ]",
    "tid": "202204061508210451927011"
  }
}
```

승인 응답의 구조는 인증 정보 조회와 같습니다. 응답 필드 전체는 [인증 정보 조회·검증](https://developers.bootpay.ai/api/identity/verify#응답)에서 확인합니다.

::: danger CI/DI 취급
`unique`(CI)와 `di`(DI)는 개인 식별 민감정보입니다. 평문으로 로그에 남기거나 프론트엔드로 내려보내지 말고, 암호화해 저장합니다.
:::

## ③ 인증번호 재전송

사용자가 인증번호를 받지 못했을 때 재전송합니다. 재전송 횟수는 **재전송 API 응답**의 `authenticate_data.number_of_realarms`로 확인합니다. 인증 정보 조회 응답에는 이 값이 들어 있지 않습니다.

::: endpoint
method: POST
url: https://api.bootpay.co.kr/v2/authenticate/realarm
auth: Basic Auth
:::

::: parameters

| 파라미터 | 타입 | 필수 | 설명 |
|---------|------|------|------|
| receipt_id | String | Y | ① 인증 요청 응답으로 받은 값 |

:::

::: code-group sync=backend

```javascript [Node.js]
await Bootpay.realarmAuthentication(receipt_id)
```

```python [Python]
bootpay.realarm_authentication(receipt_id=receipt_id)
```

```php [PHP]
BootpayApi::realarmAuthentication($receiptId);
```

```java [Java]
bootpay.realarmAuthentication(receiptId);
```

```ruby [Ruby]
bootpay.realarm_authentication(receipt_id)
```

```go [Go]
if _, err := api.RealarmAuthentication(bootpay.AuthenticationParams{ReceiptId: receiptId}); err != nil {
	return err
}
```

```csharp [.NET]
await api.RealarmAuthentication(new AuthenticationParams { receiptId = receiptId });
```

:::

::: tip 재전송 UI를 만들 때
"인증번호 재전송" 버튼에는 쿨다운(예: 30초)을 둡니다. 재전송이 무제한으로 호출되면 PG 측에서 차단될 수 있습니다. PG사에 따라 SMS 재전송 횟수에도 제한이 있어, `number_of_realarms`를 확인해 일정 횟수를 넘으면 처음부터 다시 요청하도록 안내합니다.

카운터는 PG 응답을 확인하기 전에 증가합니다. 그래서 PG 발송이 실패해 `AUTH_REALARM_FAILED`가 나도 `number_of_realarms`는 `+1` 된 상태입니다. 재시도 로직을 짤 때 이 값을 "성공한 재전송 횟수"로 해석하면 안 됩니다. PASS 방식은 재전송이 없습니다(`AUTH_REALARM_NOT_ABLE`).
:::

## PASS 앱 인증 (authenticate_type: pass)

`authenticate_type`을 `pass`로 보내면 SMS 대신 PASS 앱으로 인증을 요청합니다. 사용자는 PASS 앱에서 인증을 완료하고, 서버는 승인 API로 결과를 확인합니다.

지원 여부는 인증 PG·계약 조건에 따라 다르므로, 사용 전에 관리자 설정과 계약 스펙을 확인합니다.

## 에러 코드

::: info 공통 에러
인증·권한 관련 에러는 [에러 코드표](https://developers.bootpay.ai/api/reference/codes#인증-관련-에러)를 참고합니다.
:::

### 요청값

::: error-codes

| 코드 | 의미 | 대처 방법 |
| --- | --- | --- |
| `AUTH_NEED_PG_METHOD` (2400) | `pg` 또는 `method`가 비어 있습니다 | `pg`, `method: '본인인증'`을 채웁니다 |
| `RC_NOT_FOUND` (2000) | `receipt_id`에 해당하는 인증 건이 없습니다 | `receipt_id`를 확인합니다 |
| `RC_NAME_BLANK` (2003) | `order_name`이 비어 있습니다 | 인증 요청명을 채웁니다 |
| `RC_O_ID_BLANK` (2005) | `authentication_id`가 비어 있습니다 (메시지도 `authentication_id`를 입력하라고 안내합니다) | 가맹점 고유 인증 ID를 채웁니다 |

:::

### PG·계정 설정

::: error-codes

| 코드 | 의미 | 대처 방법 |
| --- | --- | --- |
| `AUTH_CONFIRM_METHOD_NOT_FOUND` (2406) | 해당 PG에 REST 본인인증 처리 로직이 없습니다 (HTTP 404) | REST 방식은 `다날`만 지원합니다 |
| `RC_PG_NOT_FOUND` (2001) | 요청한 PG를 찾을 수 없습니다 | 관리자에서 본인인증 PG가 등록·활성화돼 있는지 확인합니다 |
| `PM_NOT_FOUND_OR_UNIT_INVALID` (2107) | 요청한 결제수단(`method`)을 찾을 수 없습니다 (HTTP 404) | `method: '본인인증'`이 해당 PG에 열려 있는지 확인합니다 |
| `RC_RESOURCE_NOT_CONFIG` (2017) | PG 연동 설정이 사용 가능한 상태가 아닙니다 | 관리자에서 본인인증 PG 설정을 확인합니다 |
| `API_ONLY_SELLER` (600) | 판매점 계정만 호출할 수 있습니다 | 연동키가 판매점 프로젝트의 것인지 확인합니다 |

:::

### 인증 진행

::: error-codes

| 코드 | 의미 | 대처 방법 |
| --- | --- | --- |
| `AUTH_REQUEST_FAILED` (2401) | 본인인증 요청 생성에 실패했습니다 | `order_name`·`authentication_id` 등 필수값과 `identity_no`·`carrier` 를 확인 후 재시도합니다 |
| `AUTH_CONFIRM_READY_FAILED` (2402) | PG로의 SMS/PASS 발송에 실패했습니다 | `identity_no`·`phone`·`carrier` 형식과 PG 활성화 여부를 확인합니다. PG 응답 실패면 `pg_error_code`에 다날 코드가 들어오지만, `carrier`·`identity_no`·`authenticate_type` 로컬 검증에서 걸린 경우에는 `pg_error_code`가 없고 사유가 `payload.message`에만 담깁니다 |
| `AUTH_NOT_READY` (2404) | 승인 대기(`status: 51`) 상태가 아닙니다. 이미 승인 완료(`status: 12`)된 건을 다시 승인·재전송해도 같은 코드가 나옵니다 | ① 인증 요청부터 다시 진행합니다 |
| `AUTH_CONFIRM_FAILED` (2405) | OTP 승인에 실패했습니다 (OTP 불일치·만료 포함). **HTTP 500**으로 응답됩니다 | `message`/`pg_error_code`를 확인하고 재전송하거나 다시 요청합니다 |
| `AUTH_REALARM_NOT_ABLE` (2412) | SMS 방식이 아니어서 재전송할 수 없습니다 | PASS 방식은 재전송이 없습니다 |
| `AUTH_REALARM_FAILED` (2411) | SMS 재전송에 실패했습니다. **HTTP 500**으로 응답됩니다 | 처음부터 다시 요청합니다 |

:::

### 인증 정보 조회

::: error-codes

| 코드 | 의미 | 대처 방법 |
| --- | --- | --- |
| `AUTH_NOT_CONFIRMED` (2408) | 아직 승인되지 않은 인증 건입니다 | 사용자 인증 완료 후 다시 조회합니다 |
| `AUTH_EXPIRED` (2409) | 인증 확인 유효시간(30분)이 지났습니다 | 인증을 처음부터 다시 요청합니다 |
| `AUTH_NOT_FOUND` (2407) | 인증 정보를 찾지 못했습니다 | `receipt_id`를 확인합니다 |

:::

::: warning 에러 분기는 error_code로 합니다
`AUTH_REALARM_FAILED`(2411)은 한글 메시지가 정의돼 있지 않아 `message`가 `Translation missing...` 형태로 내려올 수 있습니다. 사용자에게 그대로 노출하지 말고, 분기와 로깅은 항상 `error_code` 기준으로 처리합니다.

`AUTH_CONFIRM_FAILED`(2405)·`AUTH_REALARM_FAILED`(2411)은 HTTP 500으로 응답됩니다. 4xx만 에러로 처리하는 클라이언트라면 5xx 응답 본문의 `error_code`도 함께 확인해야 합니다.
:::

## 함께 보기

- [인증 정보 조회·검증](https://developers.bootpay.ai/api/identity/verify) — 인증 정보를 조회·저장하려면
- [인증창 연동](https://developers.bootpay.ai/api/identity/sdk) — 인증창 방식으로 바꾸려면
- [에러 코드표](https://developers.bootpay.ai/api/reference/codes#본인인증-관련-에러) — 에러 코드 전체를 보려면
- [데이터 모델 설계](https://developers.bootpay.ai/api/reference/data-model) — 결과값(CI/DI) 저장 설계
