# Business Logic — JBSbatKKSmtvlMskmInfoTrkm.addSmtvlIdoInf() [68 LOC]

| Field | Value |
|-------|-------|
| Fully Qualified Name | `eo.business.service.JBSbatKKSmtvlMskmInfoTrkm` |
| Layer | Service |
| Module | `service` (Package: `eo.business.service`) |

## 1. Role

### JBSbatKKSmtvlMskmInfoTrkm.addSmtvlIdoInf()

This method is the core **KDDI discount contract movement notification registration** handler for the Smart Value (スマートバリュー) telecom service domain. It receives migration/disposition request data and persistently records a KDDI discount contract movement notification record (`KK_T_KDDI_WKEI_IDT`) into the database. The method differentiates between two business scenarios — **application submission** (when the customer's Smart Value migration request is still being processed) and **application result** (when the result of that request has arrived back from the upstream system). In each scenario, it populates a `JBSbatCommonDBInterface` data map with the appropriate notification number, status code, timestamp, service type, transaction classification, service line item number, and formatted narrative content. It then delegates to `insertByPrimaryKeys` on the `db_KK_T_KDDI_WKEI_IDT` data access layer to atomically write the record. The method generates a formatted 15-digit notification number via a sequence utility at the start, ensuring each movement notification gets a unique identifier. It returns that notification number to the caller for downstream audit or logging. The design implements a **routing/dispatch pattern** — branching on `smtvlIdoDtlCd` to apply different status and data conventions for each business path, and delegates narrative compilation to the helper method `getKddiWkeiIdtNaiyo`.

## 2. Processing Pattern (Detailed Business Logic)

```mermaid
flowchart TD
    START(["addSmtvlIdoInf(userData, outMap, smtvlIdoDtlCd)"])
    INIT["Initialize kddiWkeiIdtMap (JBSbatCommonDBInterface)"]
    SEQ["Generate kddiWkeiIdtNo via getFormatedNextSeq"]
    COND1{smtvlIdoDtlCd = CD01445_MSKM?}
    BRANCH_A["Block A: Application (申請)"]
    BRANCH_A_SET1["Set KDDI_WKEI_IDT_NO"]
    BRANCH_A_SET2["Set TAJGS_WRIB_KEI_NO from userData"]
    BRANCH_A_SET3["Set KDDI_WKEI_IDT_STAT_CD = CD01446_TCHI_FUYO (通知不要)"]
    BRANCH_A_SET4["Set KDDI_WKEI_IDT_DTM = sys timestamp"]
    BRANCH_A_SET5["Set KDDI_WKEI_IDT_SBT_CD = 1 (スマートバリュー照合依頼)"]
    BRANCH_A_TRAN{TRAN_DIV = PARAM_TRAN_DIV_ADD or ERR_CD not null?}
    BRANCH_A_TRAN_SET1["Set TAJGS_WRIB_KEI_TRAN_CD = 1 (登録)"]
    BRANCH_A_TRAN_SET2["Set TAJGS_WRIB_KEI_TRAN_CD = 2 (解約)"]
    BRANCH_A_NAIYO["Set KDDI_WKEI_IDT_NAIYO via getKddiWkeiIdtNaiyo(userData, null)"]
    BRANCH_A_SVC["Set SVC_KEI_NO from userData"]
    BRANCH_A_RSLT{ERR_CD is blank?}
    BRANCH_A_RSLT_NORM["Set KDDI_WKEI_IDT_RSLT_CD = NORMAL (正常終了), ERR_CD = null"]
    BRANCH_A_RSLT_ERR["Set KDDI_WKEI_IDT_RSLT_CD = ERR (エラー), ERR_CD = userData ERR_CD"]
    BRANCH_B["Block B: Application Result (申請結果)"]
    BRANCH_B_SET1["Set KDDI_WKEI_IDT_NO"]
    BRANCH_B_SET2["Set TAJGS_WRIB_KEI_NO from userData"]
    BRANCH_B_SET3["Set KDDI_WKEI_IDT_STAT_CD = CD01446_TCHI_STAY (通知待ち)"]
    BRANCH_B_SET4["Set KDDI_WKEI_IDT_DTM = null"]
    BRANCH_B_SET5["Set KDDI_WKEI_IDT_SBT_CD = 2 (スマートバリュー結果)"]
    BRANCH_B_TRAN{TRAN_DIV = PARAM_TRAN_DIV_ADD or ERR_CD not null?}
    BRANCH_B_TRAN_SET1["Set TAJGS_WRIB_KEI_TRAN_CD = 1 (登録)"]
    BRANCH_B_TRAN_SET2["Set TAJGS_WRIB_KEI_TRAN_CD = 2 (解約)"]
    BRANCH_B_NULL1["Set KDDI_WKEI_IDT_RSLT_CD = null"]
    BRANCH_B_NULL2["Set KDDI_WKEI_IDT_ERR_CD = null"]
    BRANCH_B_SVC2["Set SVC_KEI_NO from userData"]
    BRANCH_B_NAIYO["Set KDDI_WKEI_IDT_NAIYO via getKddiWkeiIdtNaiyo(null, outMap)"]
    INSERT["insertByPrimaryKeys on db_KK_T_KDDI_WKEI_IDT"]
    RETURN(["Return kddiWkeiIdtNo"])

    START --> INIT --> SEQ --> COND1
    COND1 -->|"Yes"| BRANCH_A
    COND1 -->|"No"| BRANCH_B
    BRANCH_A --> BRANCH_A_SET1
    BRANCH_A_SET1 --> BRANCH_A_SET2
    BRANCH_A_SET2 --> BRANCH_A_SET3
    BRANCH_A_SET3 --> BRANCH_A_SET4
    BRANCH_A_SET4 --> BRANCH_A_SET5
    BRANCH_A_SET5 --> BRANCH_A_TRAN
    BRANCH_A_TRAN -->|"True"| BRANCH_A_TRAN_SET1
    BRANCH_A_TRAN -->|"False"| BRANCH_A_TRAN_SET2
    BRANCH_A_TRAN_SET1 --> BRANCH_A_NAIYO
    BRANCH_A_TRAN_SET2 --> BRANCH_A_NAIYO
    BRANCH_A_NAIYO --> BRANCH_A_SVC
    BRANCH_A_SVC --> BRANCH_A_RSLT
    BRANCH_A_RSLT -->|"True"| BRANCH_A_RSLT_NORM
    BRANCH_A_RSLT -->|"False"| BRANCH_A_RSLT_ERR
    BRANCH_A_RSLT_NORM --> INSERT
    BRANCH_A_RSLT_ERR --> INSERT
    BRANCH_B --> BRANCH_B_SET1
    BRANCH_B_SET1 --> BRANCH_B_SET2
    BRANCH_B_SET2 --> BRANCH_B_SET3
    BRANCH_B_SET3 --> BRANCH_B_SET4
    BRANCH_B_SET4 --> BRANCH_B_SET5
    BRANCH_B_SET5 --> BRANCH_B_TRAN
    BRANCH_B_TRAN -->|"True"| BRANCH_B_TRAN_SET1
    BRANCH_B_TRAN -->|"False"| BRANCH_B_TRAN_SET2
    BRANCH_B_TRAN_SET1 --> BRANCH_B_NULL1
    BRANCH_B_TRAN_SET2 --> BRANCH_B_NULL2
    BRANCH_B_NULL1 --> BRANCH_B_SVC2
    BRANCH_B_NULL2 --> BRANCH_B_SVC2
    BRANCH_B_SVC2 --> BRANCH_B_NAIYO
    BRANCH_B_NAIYO --> INSERT
    INSERT --> RETURN
```

**CRITICAL — Constant Resolution:**

| Constant | Value | Business Meaning | Source |
|----------|-------|-----------------|--------|
| `JKKStrConst.CD01445_MSKM` | `"01445"` | Smart Value application (スマートバリュー申請) | JKKStrConst.java |
| `JKKStrConst.CD01446_TCHI_FUYO` | `"01446"` | Notification not required (通知不要) | JKKStrConst.java |
| `JKKStrConst.CD01446_TCHI_STAY` | `"01447"` | Notification pending, file created (通知待ち(ファイル作成済)) | JKKStrConst.java |
| `JKKBatConst.PARAM_TRAN_DIV_ADD` | `"0"` | Registration/creation transaction division (登録) | JKKBatConst.java |
| `KDDI_WKEI_IDT_ERR_CD_NORMAL` | `"0000"` | Normal completion (正常終了) | JBSbatKKSmtvlMskmInfoTrkm.java |
| `KDDI_WKEI_IDT_ERR_CD_ERR` | `"9999"` | Error (エラー) | JBSbatKKSmtvlMskmInfoTrkm.java |
| `SEQ_KDDI_WKEI_IDT_NO` | `"SEQ_KK_T_KDDI_WKEI_IDT_NO"` | Oracle sequence for notification number generation | JBSbatKKSmtvlMskmInfoTrkm.java |
| `TAJGS_WRIB_KEI_NO` | `"tajgs_wrib_kei_no"` | Total billing account number (合計請求契約番号) | Constant field |
| `TRAN_DIV` | `"tran_div"` | Transaction division code (処理区分) | Constant field |
| `ERR_CD` | `"err_cd"` | Error code (エラーコード) | Constant field |
| `SVC_KEI_NO_NET` | `"svc_kei_no_net"` | Service line item number (サービス契約番号) | Constant field |

## 3. Parameter Analysis

| No | Parameter Name | Type | Business Description |
|----|---------------|------|---------------------|
| 1 | `userData` | `HashMap<String, Object>` | The application data map carrying customer request information — account numbers, error codes, transaction classification codes, and service line item numbers. In the "application" branch, it supplies actual request context; in the "application result" branch, it may carry partial data. Extracted fields include `TAJGS_WRIB_KEI_NO` (total billing contract number), `TRAN_DIV` (transaction division code), `ERR_CD` (error code from upstream), and `SVC_KEI_NO_NET` (service contract number). |
| 2 | `outMap` | `JBSbatServiceInterfaceMap` | The output file map carrying application result data returned from the upstream system. Used exclusively in the "application result" branch when `smtvlIdoDtlCd` is NOT the application constant. Passed to `getKddiWkeiIdtNaiyo(null, outMap)` to compile the narrative description from the actual result data. |
| 3 | `smtvlIdoDtlCd` | `String` | Smart Value migration detail code — the routing key that determines whether this is an "application submission" or "application result" scenario. When equal to `CD01445_MSKM` ("01445"), it follows Block A (application path); otherwise, it follows Block B (application result path). |

**Instance fields accessed:**

| Field | Type | Business Description |
|-------|------|---------------------|
| `db_KK_T_KDDI_WKEI_IDT` | `JBSbatKK_T_KDDI_WKEI_IDT` | Data access object for the KDDI discount contract movement notification table (`KK_T_KDDI_WKEI_IDT`). Used to insert the prepared record. |

## 4. CRUD Operations / Called Services

| CRUD | SC / CBS | SC Code | Entity / DB | Operation Description |
|------|----------|---------|-------------|----------------------|
| R | `JCCOracleSeqUtil.getFormatedNextSeq` | - | Database Sequence | Generates a 15-digit formatted next sequence number for KDDI discount contract movement notification ID via Oracle sequence `SEQ_KK_T_KDDI_WKEI_IDT_NO` |
| CALL | `JBSbatKKSmtvlMskmInfoTrkm.getKddiWkeiIdtNaiyo` | - | - | Compiles the narrative description string for the movement notification from application data or output file map |
| C | `JDKBatCommon.insertByPrimaryKeys` | - | `KK_T_KDDI_WKEI_IDT` | Inserts the fully populated KDDI discount contract movement notification record into the database as a primary-key insert on the `db_KK_T_KDDI_WKEI_IDT` entity |
| - | `JBSbatCommonDBInterface.setValue` | - | - | Sets field values on the in-memory data map object (`kddiWkeiIdtMap`) before database insert |
| R | `JBSbatKKSmtvlMskmInfoTrkm.isNullSpace` | - | - | Utility check whether a string value is null or blank — used to determine error vs. normal completion status |
| R | `JCCBatCommon.getSysDateTimeStamp` | - | System | Returns current system timestamp for the notification date-time field (used inside the "application" branch) |

**Entity/DB Table:** `KK_T_KDDI_WKEI_IDT` — KDDI discount contract movement notification table. Stores one row per movement notification event, tracking the notification number, associated billing account, notification status, timestamps, service type, transaction classification, narrative details, service line item number, and result/error codes.

## 5. Dependency Trace

| # | Caller (Screen/Batch) | Call Chain (Full Path to this Method) | Terminal (SC / CRUD / Entity) |
|---|----------------------|--------------------------------------|-------------------------------|
| 1 | Caller: `JBSbatKKSmtvlMskmInfoTrkm.mainProp()` | `JBSbatKKSmtvlMskmInfoTrkm.mainProp()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 2 | Caller: `JKKCancelSvcKeiCC.executeSmtvlIdoInfAddCC()` | `JKKCancelSvcKeiCC.executeSmtvlIdoInfAddCC()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 3 | Caller: `JKKDslRun.dslTjitu()` | `JKKDslRun.dslTjitu()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 4 | Caller: `JKKDslRun.hTelNoDsl()` | `JKKDslRun.hTelNoDsl()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 5 | Caller: `JKKKyoseiDslRunCC.executeSmtvlIdoInfAddCC()` | `JKKKyoseiDslRunCC.executeSmtvlIdoInfAddCC()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 6 | Caller: `JKKPauseChgRsvClCC.executeAddSmtvlIdoInf()` | `JKKPauseChgRsvClCC.executeAddSmtvlIdoInf()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 7 | Caller: `JKKPauseReceptCC.executeAddSmtvlIdoInf()` | `JKKPauseReceptCC.executeAddSmtvlIdoInf()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 8 | Caller: `JKKSmtvlInfHktgiCC.callAddSmtvlIdoInf()` | `JKKSmtvlInfHktgiCC.callAddSmtvlIdoInf()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 9 | Caller: `JKKSvkeiShosaCC.runSvkeiShosa()` | `JKKSvkeiShosaCC.runSvkeiShosa()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |
| 10 | Caller: `JKKSvkeiShosaClCC.runSvkeiShosaCl()` | `JKKSvkeiShosaClCC.runSvkeiShosaCl()` -> `addSmtvlIdoInf()` | `insertByPrimaryKeys [C] KK_T_KDDI_WKEI_IDT` |

## 6. Per-Branch Detail Blocks

**Block 1** — [INITIALIZATION] `(L3909)`

Initialize the KDDI discount contract movement notification data map with a new `JBSbatCommonDBInterface` instance.

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap = new JBSbatCommonDBInterface()` // Create notification data map |

**Block 2** — [SET] `(L3912)`

Generate the formatted 15-digit KDDI discount contract movement notification number using the Oracle sequence utility.

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtNo = JCCOracleSeqUtil.getFormatedNextSeq(connection, SEQ_KDDI_WKEI_IDT_NO, "", 15)` // Generate 15-digit notification number |

**Block 3** — [IF] `(smtvlIdoDtlCd = CD01445_MSKM = "01445" / スマートバリュー申請)` `(L3915)`

Conditional branch: "Application (申請)" path. This block handles the case where the Smart Value migration request is being submitted (not yet resulted). It populates the notification record with submission-time defaults.

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_NO, kddiWkeiIdtNo)` // Set notification number [-> SET_KDDI_WKEI_IDT_NO] |
| 2 | SET | `kddiWkeiIdtMap.setValue(TAJGS_WRIB_KEI_NO, userData.get(TAJGS_WRIB_KEI_NO))` // Total billing account number [-> TAJGS_WRIB_KEI_NO] |
| 3 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_STAT_CD, CD01446_TCHI_FUYO)` // Notification status = "通知不要" (notification not required) [-> JKKStrConst.CD01446_TCHI_FUYO] |
| 4 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_DTM, JKKBatCommon.getSysDateTimeStamp())` // Notification date-time = current system timestamp [-> SET_DTM] |
| 5 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_SBT_CD, "1")` // Sub-service type code = "1" (スマートバリュー照合依頼 — Smart Value matching request) [-> SBT_CD_1] |

**Block 3.1** — [IF] `(TRAN_DIV = PARAM_TRAN_DIV_ADD || ERR_CD is not null)` `(L3926)`

Transaction division check: determine whether this migration is a registration (登録) or a cancellation (解約).

> Block 3.1.1 — [IF-TRUE] `(TRAN_DIV = PARAM_TRAN_DIV_ADD or ERR_CD not blank)`

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(TAJGS_WRIB_KEI_TRAN_CD, "1")` // Transaction code = "1" (登録 — registration) [-> TRAN_CD_1] |

> Block 3.1.2 — [ELSE]

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(TAJGS_WRIB_KEI_TRAN_CD, "2")` // Transaction code = "2" (解約 — cancellation) [-> TRAN_CD_2] |

| # | Type | Code |
|---|------|------|
| 6 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_NAIYO, getKddiWkeiIdtNaiyo(userData, null))` // Compile narrative from userData [-> CALL_getKddiWkeiIdtNaiyo_A] |
| 7 | SET | `kddiWkeiIdtMap.setValue(SVC_KEI_NO, userData.get(SVC_KEI_NO_NET))` // Service contract number [-> SVC_KEI_NO_NET] |

**Block 3.2** — [IF] `(ERR_CD is blank — 正常結果)` `(L3934)`

Result code determination: the upstream application result was successful.

> Block 3.2.1 — [IF-TRUE] `(ERR_CD is blank)`

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_RSLT_CD, KDDI_WKEI_IDT_ERR_CD_NORMAL)` // Result = "正常終了" (normal completion) [-> NORMAL] |
| 2 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_ERR_CD, null)` // Clear error code [-> ERR_CD_NULL] |

> Block 3.2.2 — [ELSE] `(ERR_CD is not blank — エラー結果)`

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_RSLT_CD, KDDI_WKEI_IDT_ERR_CD_ERR)` // Result = "エラー" (error) [-> ERR] |
| 2 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_ERR_CD, userData.get(ERR_CD))` // Store the error code from userData [-> ERR_CD_FROM_DATA] |

**Block 4** — [ELSE] `(smtvlIdoDtlCd != CD01445_MSKM / 申請結果)` `(L3941)`

Conditional branch: "Application Result (申請結果)" path. This block handles the case where the result of a prior Smart Value migration request has been received. It populates the notification record with result-specific defaults — notification status is pending (waiting for notification file generation), timestamp is null (not yet notified), and the narrative is compiled from the output file map instead of the application data.

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_NO, kddiWkeiIdtNo)` // Set notification number [-> SET_KDDI_WKEI_IDT_NO] |
| 2 | SET | `kddiWkeiIdtMap.setValue(TAJGS_WRIB_KEI_NO, userData.get(TAJGS_WRIB_KEI_NO))` // Total billing account number [-> TAJGS_WRIB_KEI_NO] |
| 3 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_STAT_CD, CD01446_TCHI_STAY)` // Notification status = "通知待ち(ファイル作成済)" (notification pending, file created) [-> JKKStrConst.CD01446_TCHI_STAY] |
| 4 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_DTM, null)` // No timestamp yet — not yet notified [-> DTM_NULL] |
| 5 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_SBT_CD, "2")` // Sub-service type code = "2" (スマートバリュー結果 — Smart Value result) [-> SBT_CD_2] |

**Block 4.1** — [IF] `(TRAN_DIV = PARAM_TRAN_DIV_ADD || ERR_CD is not null)` `(L3952)`

Transaction division check: same logic as Block 3.1, but applied to application results.

> Block 4.1.1 — [IF-TRUE] `(TRAN_DIV = PARAM_TRAN_DIV_ADD or ERR_CD not blank)`

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(TAJGS_WRIB_KEI_TRAN_CD, "1")` // Transaction code = "1" (登録 — registration) [-> TRAN_CD_1] |

> Block 4.1.2 — [ELSE]

| # | Type | Code |
|---|------|------|
| 1 | SET | `kddiWkeiIdtMap.setValue(TAJGS_WRIB_KEI_TRAN_CD, "2")` // Transaction code = "2" (解約 — cancellation) [-> TRAN_CD_2] |

| # | Type | Code |
|---|------|------|
| 6 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_RSLT_CD, null)` // Result code = null (not yet determined at result-receipt stage) [-> RSLT_NULL] |
| 7 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_ERR_CD, null)` // Error code = null [-> ERR_CD_NULL] |
| 8 | SET | `kddiWkeiIdtMap.setValue(SVC_KEI_NO, userData.get(SVC_KEI_NO_NET))` // Service contract number [-> SVC_KEI_NO_NET] |
| 9 | SET | `kddiWkeiIdtMap.setValue(KDDI_WKEI_IDT_NAIYO, getKddiWkeiIdtNaiyo(null, outMap))` // Compile narrative from output file map [-> CALL_getKddiWkeiIdtNaiyo_B] |

**Block 5** — [EXEC] `(L3965)`

Atomically insert the fully populated notification record into the database via primary-key insert. The `db_KK_T_KDDI_WKEI_IDT` is the data access layer object mapped to the `KK_T_KDDI_WKEI_IDT` table.

| # | Type | Code |
|---|------|------|
| 1 | CALL | `db_KK_T_KDDI_WKEI_IDT.insertByPrimaryKeys(kddiWkeiIdtMap)` // Persist notification record [-> INSERT KK_T_KDDI_WKEI_IDT] |

**Block 6** — [RETURN] `(L3967)`

Return the generated notification number to the caller for audit trail or downstream processing.

| # | Type | Code |
|---|------|------|
| 1 | RETURN | `return kddiWkeiIdtNo` // Return the 15-digit formatted notification number |

## 7. Glossary

| Term | Type | Business Meaning |
|------|------|------------------|
| `KDDI_WKEI_IDT_NO` | Field | KDDI discount contract movement notification number — unique 15-digit tracking ID for each movement notification event |
| `TAJGS_WRIB_KEI_NO` | Field | Total billing account number — the consolidated billing contract number associated with the Smart Value service line item |
| `KDDI_WKEI_IDT_STAT_CD` | Field | KDDI discount contract movement notification status code — indicates whether notification is pending, complete, or suppressed |
| `CD01445_MSKM` | Constant | Smart Value application code ("01445") — when `smtvlIdoDtlCd` matches this, the method treats the input as a new application |
| `CD01446_TCHI_FUYO` | Constant | Notification not required ("通知不要") — status code for application submissions where no notification is sent |
| `CD01446_TCHI_STAY` | Constant | Notification pending, file created ("通知待ち(ファイル作成済)") — status code for application results where notification is awaited |
| `KDDI_WKEI_IDT_DTM` | Field | KDDI discount contract movement notification date-time — timestamp when the notification was actually sent |
| `KDDI_WKEI_IDT_SBT_CD` | Field | KDDI discount contract movement sub-service type code — "1" = Smart Value matching request (照合依頼), "2" = Smart Value result (結果) |
| `TAJGS_WRIB_KEI_TRAN_CD` | Field | Total billing account transaction classification code — "1" = registration (登録), "2" = cancellation (解約) |
| `KDDI_WKEI_IDT_NAIYO` | Field | KDDI discount contract movement notification content — formatted narrative describing the migration event |
| `KDDI_WKEI_IDT_RSLT_CD` | Field | KDDI discount contract movement notification result code — "0000" = normal completion (正常終了), "9999" = error (エラー), null = pending |
| `KDDI_WKEI_IDT_ERR_CD` | Field | KDDI discount contract movement notification error code — stores the specific error code when result is abnormal |
| `SVC_KEI_NO` / `SVC_KEI_NO_NET` | Field | Service contract number — the internal service line item identifier for the billing account |
| `TRAN_DIV` | Field | Transaction division code — indicates whether this is a new registration (登録) or cancellation (解約) transaction |
| `ERR_CD` | Field | Error code — carries error information from the upstream application processing |
| `smtvlIdoDtlCd` | Parameter | Smart Value migration detail code — routing key that determines application vs. application-result processing path |
| Smart Value (スマートバリュー) | Business term | NTT Docomo's bundled telecom service offering combining mobile, fixed-line, and TV services under a single billing account |
| KDDI割引契約 | Business term | KDDI discount contract — a billing arrangement where KDDI telecommunications services receive discounted rates |
| 異動通知 (Ido Tsuchi) | Business term | Movement notification — an alert record sent to track changes (migration, cancellation, modification) on a service contract |
| 照合依頼 (Shougou Irai) | Business term | Matching request — a service type code "1" indicating a request to match/verify Smart Value service data |
| 申請 (Shinsei) | Business term | Application — the initial submission of a Smart Value migration request |
| 申請結果 (Shinsei Kekka) | Business term | Application result — the response/data returned after the upstream system processes the application |
| 登録 (Touroku) | Business term | Registration — a transaction type indicating a new service addition or creation |
| 解約 (Kaiya) | Business term | Cancellation — a transaction type indicating a service disconnection or termination |
| `KK_T_KDDI_WKEI_IDT` | Table | KDDI discount contract movement notification table — the database table storing all movement notification records |
| `getFormatedNextSeq` | Method | Sequence number generator utility — produces a zero-padded, fixed-length (15-digit) next value from an Oracle database sequence |
| `getKddiWkeiIdtNaiyo` | Method | KDDI discount contract movement notification content compiler — a private helper method that formats the narrative description from either application data or result output data |
