Skip to main content

샘플 데이터 구조 분석

sampleData 검증 페이로드를 검사하여 필드 경로, 값 형태, 권장 sectionType 선택지, 대체 섹션 타입, 추천 테이블 열 및 바인딩 제안을 담은 구조화된 맵을 수신합니다.

헤드리스 리포트 작성 및 AI 에이전트 파이프라인에서는 시뮬레이션 응답 조회에서 페이로드를 가져오거나 SmartBatch 행을 캡처한 직후 이 엔드포인트를 호출하세요. dataPath 문자열을 추측하거나 취약한 JSON 순회 로직을 작성하는 대신, UI나 에이전트가 분석된 nodes 및 batch 메타데이터를 사용해 유효한 sections를 직접 구성하거나 템플릿 레이아웃 생성용 prompt 컨텍스트를 보강할 수 있습니다. 탐색기(walker)는 최대 깊이 5 및 최대 600개 노드까지 검사합니다.

엔드포인트​

POST https://api.verifik.co/v2/smart-report-templates/introspect

Smart-Agent 프록시(https://ai.verifik.co)도 동일한 /v2/... 경로를 제공하며 본인의 Authorization: Bearer <VERIFIK_JWT> 헤더가 필요합니다.

헤더​

이름값
Content-Typeapplication/json
Acceptapplication/json
AuthorizationBearer <VERIFIK_JWT>

요청 본문​

이름타입필수설명
sampleDataobject예선택적 batchName(string), rowIndex(number), inputData(object), results(object)를 포함하는 샘플 검증 페이로드.

요청​

const fetch = require("node-fetch");

async function run() {
const res = await fetch(
"https://api.verifik.co/v2/smart-report-templates/introspect",
{
method: "POST",
headers: {
"Content-Type": "application/json",
Accept: "application/json",
Authorization: `Bearer ${process.env.VERIFIK_JWT}`,
},
body: JSON.stringify({
sampleData: {
batchName: "Driver Onboarding",
rowIndex: 0,
inputData: {
documentType: "CC",
documentNumber: "1020304050",
},
results: {
identity: {
fullName: "Mateo Rojas",
status: "active",
},
fines: [
{ code: "C02", amount: 580000, status: "pending" },
],
},
},
}),
}
);

console.log(await res.json());
}

run();

응답​

{
"data": {
"nodes": [
{
"path": "results.identity",
"shape": "object",
"sectionType": "keyValueGrid",
"alternatives": ["card", "table"],
"columns": [
{ "key": "fullName", "label": "Full Name" },
{ "key": "status", "label": "Status" }
],
"suggestion": {
"type": "keyValueGrid",
"dataPath": "results.identity"
}
},
{
"path": "results.fines",
"shape": "array",
"sectionType": "dataTable",
"alternatives": ["repeater", "table"],
"columns": [
{ "key": "code", "label": "Code" },
{ "key": "amount", "label": "Amount" },
{ "key": "status", "label": "Status" }
],
"suggestion": {
"type": "dataTable",
"dataPath": "results.fines"
}
}
],
"batch": [
{
"path": "inputData",
"shape": "object",
"sectionType": "keyValueGrid"
}
],
"count": 2,
"truncated": false
}
}

참고 사항​

  • 순회는 깊이 5에서 중단되며 최대 600개 노드로 제한됩니다. 매우 큰 페이로드가 제한에 도달하면 truncated가 true가 됩니다.
  • 이 엔드포인트는 읽기 전용 및 무상태(stateless)로 동작하며, 템플릿을 저장하거나 검증 크레딧을 소모하지 않습니다.

관련 문서​