- Harness: kintex-mobile-dev agent + kintex-mobile-orchestrator skill (WISE mobile ref, Stitch-first design rule, dual app targets B2B/B2C) - design.md v2.1: full 84-screen inventory (web 51 / admin 10 / public 8 / mobile 15) with Stitch prompts incl. ticketing (SCR-P7/P8, M14/M15) - PLANNING v3.1: unified account + split signup tracks (2FA required for staff, light signup/guest for visitors), one codebase / two app targets - Deliverables: dev plan (21s), user/operator/developer guides (17/14/15s), program spec (44s, 65 programs, 8 flowcharts), DA (DB design 14s + table spec xlsx 35 tables/299 cols) - Benchmark: ticketing-app-benchmark.md (7 apps) -> IMPLEMENTATION_BACKLOG Phase F (14 items) - Stitch: 23 generated screens saved (mobile 10, admin 6, web core 5, ticket 2) - mobile/: Expo scaffold (SDK 51, expo-router, secure store JWT) - frontend: SCR-13~17 QA fixes, icons.tsx, kintexEvents, V10 seed migration - ci/: KINTEX CI logo assets Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
106 lines
2.4 KiB
TypeScript
106 lines
2.4 KiB
TypeScript
/*
|
|
* 백엔드 API 계약 타입 (단일 출처: _workspace/01_backend_contracts.md · 04_backend_public_auth.md)
|
|
* ★ 백엔드 응답 shape과 정확히 일치해야 한다. 불일치 발견 시 _workspace/에 기록·보고.
|
|
*/
|
|
|
|
// ── 0-1 응답 봉투 ──
|
|
export interface ApiError {
|
|
code: ApiErrorCode;
|
|
message: string;
|
|
}
|
|
export interface ApiResponse<T> {
|
|
success: boolean;
|
|
data: T | null;
|
|
error: ApiError | null;
|
|
}
|
|
export interface PageResponse<T> {
|
|
items: T[];
|
|
page: number;
|
|
size: number;
|
|
total: number;
|
|
}
|
|
|
|
// ── 0-2 오류 코드 ──
|
|
export type ApiErrorCode =
|
|
| 'VALIDATION'
|
|
| 'UNAUTHORIZED'
|
|
| 'FORBIDDEN'
|
|
| 'NOT_FOUND'
|
|
| 'CONFLICT'
|
|
| 'EMAIL_TAKEN'
|
|
| 'COMPLIANCE_BLOCKED'
|
|
| 'RENDER_QUOTA_EXCEEDED'
|
|
| 'NOT_REGISTERED_COMPANY'
|
|
| 'NOT_IMPLEMENTED'
|
|
| 'ACCOUNT_LOCKED'
|
|
| 'OTP_REQUIRED'
|
|
| 'OTP_INVALID'
|
|
| 'INTERNAL';
|
|
|
|
// ── 0-5 역할 ──
|
|
export type EventRole = 'ORGANIZER' | 'EXHIBITOR' | 'CONTRACTOR' | 'HALL_MANAGER';
|
|
|
|
// ── 2. 인증·워크스페이스 (SCR-01) ──
|
|
export interface WorkspaceDto {
|
|
eventId: string;
|
|
eventName: string;
|
|
startDate: string;
|
|
endDate: string;
|
|
hallLabel: string;
|
|
myRole: EventRole;
|
|
dday: number;
|
|
}
|
|
export interface AuthUser {
|
|
userId: string;
|
|
displayName: string;
|
|
hallManager: boolean;
|
|
}
|
|
export interface LoginResponse {
|
|
accessToken: string;
|
|
expiresInSeconds: number;
|
|
user: AuthUser;
|
|
workspaces: WorkspaceDto[];
|
|
}
|
|
|
|
// ── 공개 인증 (04_backend_public_auth.md) ──
|
|
export interface RegisterRequest {
|
|
email: string;
|
|
displayName: string;
|
|
password: string;
|
|
companyName?: string;
|
|
inviteCode?: string;
|
|
}
|
|
export interface RegisterResponse {
|
|
userId: string;
|
|
email: string;
|
|
displayName: string;
|
|
joinedEvent: string | null;
|
|
}
|
|
export interface MessageResponse {
|
|
message: string;
|
|
}
|
|
|
|
// ── 6. M5 나노바나나 RenderJob (SCR-06/12) ──
|
|
export type RenderJobStatus = 'QUEUED' | 'RUNNING' | 'DONE' | 'FAILED';
|
|
export interface RenderJobDto {
|
|
jobId: string;
|
|
boothId: string;
|
|
shotPreset: string; // S1..S7
|
|
status: RenderJobStatus;
|
|
imageUrl: string | null;
|
|
schemaHash: string | null;
|
|
modelVersion: string | null;
|
|
/** AI 생성 이미지 고지 — 항상 true (제거 불가). */
|
|
watermarkRequired: boolean;
|
|
watermarkText: string;
|
|
notice?: string;
|
|
createdAt?: string;
|
|
}
|
|
|
|
// ── 헬스체크 ──
|
|
export interface HealthDto {
|
|
status: string;
|
|
service: string;
|
|
time: string;
|
|
}
|