create-entity-server 0.0.26 → 0.0.27
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/template/.env.example +26 -0
- package/template/configs/auth/cors.json +15 -0
- package/template/configs/auth/identity.json +27 -0
- package/template/configs/auth/jwt.json +12 -0
- package/template/configs/{oauth.json → auth/oauth.json} +7 -4
- package/template/configs/auth/password.json +33 -0
- package/template/configs/auth/privacy_policy.json +28 -0
- package/template/configs/{security.json → auth/security.json} +4 -2
- package/template/configs/auth/two_factor.json +12 -0
- package/template/configs/extensions/pg.json +37 -0
- package/template/configs/extensions/tax-invoice.json +59 -0
- package/template/configs/keys/.gitkeep +0 -0
- package/template/configs/keys/apns.p8.example +7 -0
- package/template/configs/keys/firebase.pem.example +7 -0
- package/template/configs/notification/alimtalk.json +75 -0
- package/template/configs/notification/sms.json +54 -0
- package/template/configs/server.json +1 -0
- package/template/entities/README.md +13 -16
- package/template/entities/System/Auth/account.json +17 -1
- package/template/entities/System/Auth/account_audit.json +23 -0
- package/template/entities/System/Auth/account_device.json +63 -0
- package/template/entities/System/Auth/account_login_log.json +54 -0
- package/template/entities/System/Auth/account_oauth.json +45 -0
- package/template/entities/System/Auth/api_keys.json +1 -1
- package/template/entities/System/Auth/identity_verification.json +95 -0
- package/template/entities/System/Auth/license.json +1 -1
- package/template/entities/System/Auth/password_history.json +20 -0
- package/template/entities/System/Auth/rbac_roles.json +1 -1
- package/template/entities/System/Backup/backup_log.json +62 -0
- package/template/entities/System/Email/smtp_log.json +83 -0
- package/template/entities/System/Email/smtp_msg.json +104 -0
- package/template/entities/System/Notification/alimtalk_log.json +45 -0
- package/template/entities/System/Notification/alimtalk_msg.json +39 -0
- package/template/entities/System/Notification/friendtalk_log.json +48 -0
- package/template/entities/System/Notification/friendtalk_msg.json +63 -0
- package/template/entities/System/Notification/sms_log.json +26 -0
- package/template/entities/System/Notification/sms_msg.json +52 -0
- package/template/entities/System/Notification/sms_verification.json +40 -0
- package/template/entities/System/Payment/pg_cancel.json +45 -0
- package/template/entities/System/Payment/pg_order.json +88 -0
- package/template/entities/System/Payment/pg_webhook_log.json +37 -0
- package/template/entities/System/Push/push_log.json +71 -0
- package/template/entities/System/Push/push_msg.json +55 -0
- package/template/entities/System/Storage/file_backup_log.json +46 -0
- package/template/entities/System/Storage/file_download_log.json +41 -0
- package/template/entities/System/Storage/file_meta.json +59 -0
- package/template/entities/System/system_audit_log.json +2 -1
- package/template/entities/company.json +1 -1
- package/template/entities/{product.json → goods.json} +6 -10
- package/template/entities/todo.json +1 -1
- package/template/templates/email/account/dormancy_warning.html +20 -0
- package/template/templates/email/account/password_expiry_warning.html +21 -0
- package/template/templates/email/auth/2fa_disabled.html +23 -0
- package/template/templates/email/auth/2fa_recovery_regenerated.html +31 -0
- package/template/templates/email/auth/2fa_setup_complete.html +43 -0
- package/template/templates/email/auth/email_verification.html +18 -0
- package/template/templates/email/auth/force_reset.html +18 -0
- package/template/templates/email/auth/password_reset.html +19 -0
- package/template/templates/email/auth/verification.html +15 -0
- package/template/templates/email/auth/verification_link.html +25 -0
- package/template/templates/email/auth/welcome.html +18 -0
- package/template/templates/email/backup/backup_completed.html +35 -0
- package/template/templates/email/backup/backup_failed.html +27 -0
- package/template/templates/email/backup/backup_partial.html +31 -0
- package/template/templates/email/layout.html +47 -0
- package/template/templates/email/order/order_confirmation.html +30 -0
- package/template/templates/email/storage/storage_quota_exceeded.html +37 -0
- package/template/templates/email/storage/storage_quota_warning.html +37 -0
- package/template/configs/cors.json +0 -7
- package/template/configs/jwt.json +0 -8
- package/template/entities/Account/account_audit.json +0 -16
- /package/template/configs/{backup.json → extensions/backup.json} +0 -0
- /package/template/configs/{storage.json → extensions/storage.json} +0 -0
- /package/template/configs/{push.json → notification/push.json} +0 -0
- /package/template/configs/{smtp.json → notification/smtp.json} +0 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "account_device",
|
|
3
|
+
"description": "계정 기기 정보 및 푸시 토큰 관리. JWT 인증 시 account_seq로 계정과 연결. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"license_scope": false,
|
|
5
|
+
"index": {
|
|
6
|
+
"account_seq": {
|
|
7
|
+
"comment": "계정seq (JWT 인증 시 필수. HMAC 인증은 nullable)"
|
|
8
|
+
},
|
|
9
|
+
"id": {
|
|
10
|
+
"comment": "기기ID"
|
|
11
|
+
},
|
|
12
|
+
"push_enabled": {
|
|
13
|
+
"comment": "푸시 수신 허용",
|
|
14
|
+
"type": "bool",
|
|
15
|
+
"default": true
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"unique": [
|
|
19
|
+
[
|
|
20
|
+
"id",
|
|
21
|
+
"account_seq"
|
|
22
|
+
]
|
|
23
|
+
],
|
|
24
|
+
"fields": {
|
|
25
|
+
"device_type": {
|
|
26
|
+
"comment": "기기유형",
|
|
27
|
+
"type": [
|
|
28
|
+
"mobile",
|
|
29
|
+
"tablet",
|
|
30
|
+
"desktop",
|
|
31
|
+
"watch"
|
|
32
|
+
],
|
|
33
|
+
"default": "mobile"
|
|
34
|
+
},
|
|
35
|
+
"platform": {
|
|
36
|
+
"comment": "플랫폼",
|
|
37
|
+
"type": [
|
|
38
|
+
"android",
|
|
39
|
+
"ios",
|
|
40
|
+
"web",
|
|
41
|
+
"windows",
|
|
42
|
+
"macos",
|
|
43
|
+
"linux"
|
|
44
|
+
]
|
|
45
|
+
},
|
|
46
|
+
"browser": {
|
|
47
|
+
"comment": "브라우저"
|
|
48
|
+
},
|
|
49
|
+
"browser_version": {
|
|
50
|
+
"comment": "브라우저버전"
|
|
51
|
+
},
|
|
52
|
+
"push_token": {
|
|
53
|
+
"comment": "푸시 디바이스 토큰",
|
|
54
|
+
"nullable": true
|
|
55
|
+
},
|
|
56
|
+
"last_login_time": {
|
|
57
|
+
"comment": "마지막로그인시각"
|
|
58
|
+
},
|
|
59
|
+
"last_ip_addr": {
|
|
60
|
+
"comment": "마지막IP주소"
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "account_login_log",
|
|
3
|
+
"description": "account_login_log 엔티티. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"compress": true,
|
|
5
|
+
"index": {
|
|
6
|
+
"browser": {
|
|
7
|
+
"comment": "브라우저"
|
|
8
|
+
},
|
|
9
|
+
"country_code": {
|
|
10
|
+
"comment": "국가코드 iso2"
|
|
11
|
+
},
|
|
12
|
+
"device_id": {
|
|
13
|
+
"comment": "디바이스 ID",
|
|
14
|
+
"type": "string"
|
|
15
|
+
},
|
|
16
|
+
"device_type": {
|
|
17
|
+
"comment": "장치종류"
|
|
18
|
+
},
|
|
19
|
+
"domain": {
|
|
20
|
+
"comment": "도메인"
|
|
21
|
+
},
|
|
22
|
+
"email": {
|
|
23
|
+
"comment": "로그인 이메일"
|
|
24
|
+
},
|
|
25
|
+
"ip_address": {
|
|
26
|
+
"comment": "접속아이피"
|
|
27
|
+
},
|
|
28
|
+
"is_success": {
|
|
29
|
+
"comment": "성공여부"
|
|
30
|
+
},
|
|
31
|
+
"language": {
|
|
32
|
+
"comment": "언어"
|
|
33
|
+
},
|
|
34
|
+
"user_seq": {
|
|
35
|
+
"comment": "사용자번호"
|
|
36
|
+
},
|
|
37
|
+
"auth_method": {
|
|
38
|
+
"comment": "인증 방식",
|
|
39
|
+
"type": ["password", "oauth", "2fa_totp", "2fa_recovery"],
|
|
40
|
+
"default": "password"
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
"fields": {
|
|
44
|
+
"location_info": {
|
|
45
|
+
"comment": "위치"
|
|
46
|
+
},
|
|
47
|
+
"passwd": {
|
|
48
|
+
"comment": "로그인 비밀번호"
|
|
49
|
+
},
|
|
50
|
+
"user_agent": {
|
|
51
|
+
"comment": "User Agent"
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "account_oauth",
|
|
3
|
+
"description": "소셜 로그인 OAuth 프로바이더 연동 정보. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"history": false,
|
|
5
|
+
"hard_delete": true,
|
|
6
|
+
"index": {
|
|
7
|
+
"account_seq": {
|
|
8
|
+
"required": true,
|
|
9
|
+
"comment": "계정 seq"
|
|
10
|
+
},
|
|
11
|
+
"provider": {
|
|
12
|
+
"type": ["google", "github", "naver", "kakao", "apple"],
|
|
13
|
+
"required": true
|
|
14
|
+
},
|
|
15
|
+
"provider_id": {
|
|
16
|
+
"type": "string",
|
|
17
|
+
"required": true,
|
|
18
|
+
"comment": "프로바이더 고유 사용자 ID"
|
|
19
|
+
},
|
|
20
|
+
"status": {
|
|
21
|
+
"type": ["active", "unlinked"],
|
|
22
|
+
"default": "active"
|
|
23
|
+
}
|
|
24
|
+
},
|
|
25
|
+
"fields": {
|
|
26
|
+
"email": { "type": "email", "comment": "프로바이더에서 제공한 이메일" },
|
|
27
|
+
"name": { "type": "string", "comment": "프로바이더에서 제공한 이름" },
|
|
28
|
+
"profile_image": { "type": "string", "comment": "프로필 이미지 URL" },
|
|
29
|
+
"access_token": {
|
|
30
|
+
"type": "string",
|
|
31
|
+
"comment": "OAuth access token (암호화 저장)"
|
|
32
|
+
},
|
|
33
|
+
"refresh_token": {
|
|
34
|
+
"type": "string",
|
|
35
|
+
"comment": "OAuth refresh token (암호화 저장)"
|
|
36
|
+
},
|
|
37
|
+
"token_expires_at": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"comment": "access token 만료 시각 (RFC3339)"
|
|
40
|
+
},
|
|
41
|
+
"raw": { "type": "json", "comment": "프로바이더 원본 응답 (디버깅용)" },
|
|
42
|
+
"linked_at": { "type": "string", "comment": "연결 시각" },
|
|
43
|
+
"unlinked_at": { "type": "string", "comment": "연결 해제 시각" }
|
|
44
|
+
}
|
|
45
|
+
}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "identity_verification",
|
|
3
|
+
"description": "휴대폰 본인인증 요청 및 결과 저장. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"history": false,
|
|
5
|
+
"hard_delete": false,
|
|
6
|
+
"compress": true,
|
|
7
|
+
"index": {
|
|
8
|
+
"request_id": {
|
|
9
|
+
"type": "string",
|
|
10
|
+
"required": true,
|
|
11
|
+
"unique": true,
|
|
12
|
+
"comment": "인증 요청 고유 ID (32바이트 hex)"
|
|
13
|
+
},
|
|
14
|
+
"status": {
|
|
15
|
+
"type": ["pending", "verified", "failed", "expired"],
|
|
16
|
+
"default": "pending"
|
|
17
|
+
},
|
|
18
|
+
"purpose": {
|
|
19
|
+
"type": [
|
|
20
|
+
"signup",
|
|
21
|
+
"find_account",
|
|
22
|
+
"password_reset",
|
|
23
|
+
"adult_verify",
|
|
24
|
+
"identity_change"
|
|
25
|
+
],
|
|
26
|
+
"required": true
|
|
27
|
+
},
|
|
28
|
+
"provider": {
|
|
29
|
+
"type": ["nice", "kmc", "danal"],
|
|
30
|
+
"required": true
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"fields": {
|
|
34
|
+
"ci_hash": {
|
|
35
|
+
"type": "string",
|
|
36
|
+
"comment": "CI의 SHA-256 해시 (중복 조회용)"
|
|
37
|
+
},
|
|
38
|
+
"di": {
|
|
39
|
+
"type": "string",
|
|
40
|
+
"comment": "DI 원문 (암호화 저장)"
|
|
41
|
+
},
|
|
42
|
+
"name": {
|
|
43
|
+
"type": "string",
|
|
44
|
+
"comment": "인증된 실명"
|
|
45
|
+
},
|
|
46
|
+
"birth_date": {
|
|
47
|
+
"type": "string",
|
|
48
|
+
"comment": "생년월일 (YYYYMMDD)"
|
|
49
|
+
},
|
|
50
|
+
"gender": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"comment": "성별 (M/F)"
|
|
53
|
+
},
|
|
54
|
+
"carrier": {
|
|
55
|
+
"type": "string",
|
|
56
|
+
"comment": "통신사 코드"
|
|
57
|
+
},
|
|
58
|
+
"phone": {
|
|
59
|
+
"type": "string",
|
|
60
|
+
"comment": "인증 휴대폰 번호"
|
|
61
|
+
},
|
|
62
|
+
"nationality": {
|
|
63
|
+
"type": "string",
|
|
64
|
+
"comment": "내/외국인 (local/foreign)"
|
|
65
|
+
},
|
|
66
|
+
"account_seq": {
|
|
67
|
+
"type": "int",
|
|
68
|
+
"comment": "연결된 계정 seq (인증 완료 후 설정)"
|
|
69
|
+
},
|
|
70
|
+
"ip_address": {
|
|
71
|
+
"type": "string",
|
|
72
|
+
"comment": "요청 IP 주소"
|
|
73
|
+
},
|
|
74
|
+
"user_agent": {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"comment": "요청 User-Agent"
|
|
77
|
+
},
|
|
78
|
+
"verified_at": {
|
|
79
|
+
"type": "string",
|
|
80
|
+
"comment": "인증 완료 시각 (RFC3339)"
|
|
81
|
+
},
|
|
82
|
+
"expires_at": {
|
|
83
|
+
"type": "string",
|
|
84
|
+
"comment": "요청 만료 시각 (RFC3339)"
|
|
85
|
+
},
|
|
86
|
+
"error_message": {
|
|
87
|
+
"type": "string",
|
|
88
|
+
"comment": "실패 시 에러 메시지"
|
|
89
|
+
},
|
|
90
|
+
"raw_response": {
|
|
91
|
+
"type": "json",
|
|
92
|
+
"comment": "중계사 원본 응답 (디버깅용, 암호화)"
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "password_history",
|
|
3
|
+
"description": "비밀번호 변경 이력 (재사용 금지 정책용) 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"hard_delete": true,
|
|
5
|
+
"index": {
|
|
6
|
+
"account_seq": {
|
|
7
|
+
"comment": "계정 seq",
|
|
8
|
+
"type": "integer",
|
|
9
|
+
"required": true
|
|
10
|
+
}
|
|
11
|
+
},
|
|
12
|
+
"fields": {
|
|
13
|
+
"passwd_hash": {
|
|
14
|
+
"comment": "변경 시점의 비밀번호 해시 (salt 포함)"
|
|
15
|
+
},
|
|
16
|
+
"changed_time": {
|
|
17
|
+
"comment": "비밀번호 변경 시각"
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
}
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "backup_log",
|
|
3
|
+
"description": "백업 작업 이력. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"license_scope": false,
|
|
5
|
+
"hard_delete": true,
|
|
6
|
+
"history": false,
|
|
7
|
+
"compress": true,
|
|
8
|
+
"index": {
|
|
9
|
+
"backup_type": {
|
|
10
|
+
"type": [
|
|
11
|
+
"data",
|
|
12
|
+
"file",
|
|
13
|
+
"full"
|
|
14
|
+
],
|
|
15
|
+
"required": true
|
|
16
|
+
},
|
|
17
|
+
"finished_time": {},
|
|
18
|
+
"started_time": {},
|
|
19
|
+
"status": {
|
|
20
|
+
"type": [
|
|
21
|
+
"running",
|
|
22
|
+
"completed",
|
|
23
|
+
"partial",
|
|
24
|
+
"failed"
|
|
25
|
+
],
|
|
26
|
+
"required": true
|
|
27
|
+
}
|
|
28
|
+
},
|
|
29
|
+
"fields": {
|
|
30
|
+
"session_id": {
|
|
31
|
+
"description": "백업 세션 ID (타임스탬프)"
|
|
32
|
+
},
|
|
33
|
+
"db_groups": {
|
|
34
|
+
"type": "varchar(500)",
|
|
35
|
+
"description": "백업된 DB 그룹 목록 (JSON)"
|
|
36
|
+
},
|
|
37
|
+
"entity_count": {
|
|
38
|
+
"description": "백업된 엔티티 수"
|
|
39
|
+
},
|
|
40
|
+
"total_records": {
|
|
41
|
+
"description": "총 레코드 수"
|
|
42
|
+
},
|
|
43
|
+
"total_bytes": {
|
|
44
|
+
"description": "총 바이트"
|
|
45
|
+
},
|
|
46
|
+
"error_count": {
|
|
47
|
+
"description": "에러 수"
|
|
48
|
+
},
|
|
49
|
+
"error_message": {
|
|
50
|
+
"type": "varchar(2000)",
|
|
51
|
+
"nullable": true,
|
|
52
|
+
"description": "에러 상세"
|
|
53
|
+
},
|
|
54
|
+
"exec_instance": {
|
|
55
|
+
"description": "실행 서버 인스턴스 ID"
|
|
56
|
+
},
|
|
57
|
+
"manifest_path": {
|
|
58
|
+
"description": "manifest.json 경로"
|
|
59
|
+
}
|
|
60
|
+
},
|
|
61
|
+
"read_only": true
|
|
62
|
+
}
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "smtp_log",
|
|
3
|
+
"description": "SMTP 이메일 발송 이력. 발송 결과 추적 및 재시도 관리용. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"license_scope": false,
|
|
5
|
+
"hard_delete": true,
|
|
6
|
+
"history": false,
|
|
7
|
+
"compress": true,
|
|
8
|
+
"index": {
|
|
9
|
+
"attempt_time": {
|
|
10
|
+
"comment": "처리 시작(claim) 시각"
|
|
11
|
+
},
|
|
12
|
+
"provider": {
|
|
13
|
+
"type": "varchar(50)"
|
|
14
|
+
},
|
|
15
|
+
"retry_count": {
|
|
16
|
+
"type": "uint",
|
|
17
|
+
"default": 0
|
|
18
|
+
},
|
|
19
|
+
"sent_time": {
|
|
20
|
+
"comment": "발송 완료 시각"
|
|
21
|
+
},
|
|
22
|
+
"smtp_msg_seq": {
|
|
23
|
+
"comment": "원본 smtp_msg seq"
|
|
24
|
+
},
|
|
25
|
+
"status": {
|
|
26
|
+
"type": [
|
|
27
|
+
"pending",
|
|
28
|
+
"processing",
|
|
29
|
+
"sent",
|
|
30
|
+
"failed",
|
|
31
|
+
"expired"
|
|
32
|
+
],
|
|
33
|
+
"default": "pending",
|
|
34
|
+
"required": true
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
"fields": {
|
|
38
|
+
"from": {
|
|
39
|
+
"comment": "발신자"
|
|
40
|
+
},
|
|
41
|
+
"to": {
|
|
42
|
+
"type": "text",
|
|
43
|
+
"comment": "수신자 목록"
|
|
44
|
+
},
|
|
45
|
+
"cc": {
|
|
46
|
+
"type": "text",
|
|
47
|
+
"nullable": true
|
|
48
|
+
},
|
|
49
|
+
"bcc": {
|
|
50
|
+
"type": "text",
|
|
51
|
+
"nullable": true
|
|
52
|
+
},
|
|
53
|
+
"subject": {
|
|
54
|
+
"comment": "제목"
|
|
55
|
+
},
|
|
56
|
+
"body_text": {
|
|
57
|
+
"type": "mediumtext",
|
|
58
|
+
"nullable": true
|
|
59
|
+
},
|
|
60
|
+
"body_html": {
|
|
61
|
+
"type": "mediumtext",
|
|
62
|
+
"nullable": true
|
|
63
|
+
},
|
|
64
|
+
"attachments": {
|
|
65
|
+
"type": "text",
|
|
66
|
+
"nullable": true
|
|
67
|
+
},
|
|
68
|
+
"error_message": {
|
|
69
|
+
"type": "text",
|
|
70
|
+
"nullable": true
|
|
71
|
+
},
|
|
72
|
+
"message_id": {
|
|
73
|
+
"nullable": true,
|
|
74
|
+
"comment": "SMTP Message-ID 헤더"
|
|
75
|
+
},
|
|
76
|
+
"ref_entity": {
|
|
77
|
+
"nullable": true
|
|
78
|
+
},
|
|
79
|
+
"ref_seq": {
|
|
80
|
+
"nullable": true
|
|
81
|
+
}
|
|
82
|
+
}
|
|
83
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "smtp_msg",
|
|
3
|
+
"description": "SMTP 이메일 트리거 엔티티. insert 시 smtp hook으로 비동기 발송. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"hard_delete": true,
|
|
5
|
+
"history": false,
|
|
6
|
+
"index": {
|
|
7
|
+
"provider": {
|
|
8
|
+
"comment": "사용할 SMTP 프로바이더 키 (미지정 시 default)",
|
|
9
|
+
"type": "varchar(50)"
|
|
10
|
+
},
|
|
11
|
+
"status": {
|
|
12
|
+
"type": [
|
|
13
|
+
"queued",
|
|
14
|
+
"sent",
|
|
15
|
+
"failed"
|
|
16
|
+
],
|
|
17
|
+
"default": "queued",
|
|
18
|
+
"required": true
|
|
19
|
+
}
|
|
20
|
+
},
|
|
21
|
+
"fields": {
|
|
22
|
+
"from": {
|
|
23
|
+
"nullable": true,
|
|
24
|
+
"comment": "발신자 이메일 (미지정 시 프로바이더 기본값)"
|
|
25
|
+
},
|
|
26
|
+
"to": {
|
|
27
|
+
"type": "text",
|
|
28
|
+
"required": true,
|
|
29
|
+
"comment": "수신자 이메일 (쉼표 구분 또는 JSON 배열)"
|
|
30
|
+
},
|
|
31
|
+
"cc": {
|
|
32
|
+
"type": "text",
|
|
33
|
+
"nullable": true,
|
|
34
|
+
"comment": "참조 (쉼표 구분 또는 JSON 배열)"
|
|
35
|
+
},
|
|
36
|
+
"bcc": {
|
|
37
|
+
"type": "text",
|
|
38
|
+
"nullable": true,
|
|
39
|
+
"comment": "숨은 참조 (쉼표 구분 또는 JSON 배열)"
|
|
40
|
+
},
|
|
41
|
+
"subject": {
|
|
42
|
+
"required": true,
|
|
43
|
+
"comment": "이메일 제목"
|
|
44
|
+
},
|
|
45
|
+
"body_text": {
|
|
46
|
+
"type": "mediumtext",
|
|
47
|
+
"nullable": true,
|
|
48
|
+
"comment": "텍스트 본문"
|
|
49
|
+
},
|
|
50
|
+
"body_html": {
|
|
51
|
+
"type": "mediumtext",
|
|
52
|
+
"nullable": true,
|
|
53
|
+
"comment": "HTML 본문"
|
|
54
|
+
},
|
|
55
|
+
"template_name": {
|
|
56
|
+
"nullable": true,
|
|
57
|
+
"comment": "템플릿 이름 (templates/ 디렉터리)"
|
|
58
|
+
},
|
|
59
|
+
"template_data": {
|
|
60
|
+
"type": "text",
|
|
61
|
+
"nullable": true,
|
|
62
|
+
"comment": "템플릿 변수 JSON"
|
|
63
|
+
},
|
|
64
|
+
"attachments": {
|
|
65
|
+
"type": "text",
|
|
66
|
+
"nullable": true,
|
|
67
|
+
"comment": "첨부 file_meta seq 배열 (JSON)"
|
|
68
|
+
},
|
|
69
|
+
"reply_to": {
|
|
70
|
+
"nullable": true,
|
|
71
|
+
"comment": "회신 주소"
|
|
72
|
+
},
|
|
73
|
+
"ref_entity": {
|
|
74
|
+
"nullable": true,
|
|
75
|
+
"comment": "참조 엔티티 이름"
|
|
76
|
+
},
|
|
77
|
+
"ref_seq": {
|
|
78
|
+
"nullable": true,
|
|
79
|
+
"comment": "참조 레코드 seq"
|
|
80
|
+
}
|
|
81
|
+
},
|
|
82
|
+
"hooks": {
|
|
83
|
+
"after_insert": [
|
|
84
|
+
{
|
|
85
|
+
"type": "smtp",
|
|
86
|
+
"provider": "${new.provider}",
|
|
87
|
+
"from": "${new.from}",
|
|
88
|
+
"to": "${new.to}",
|
|
89
|
+
"cc": "${new.cc}",
|
|
90
|
+
"bcc": "${new.bcc}",
|
|
91
|
+
"subject": "${new.subject}",
|
|
92
|
+
"body_text": "${new.body_text}",
|
|
93
|
+
"body_html": "${new.body_html}",
|
|
94
|
+
"template_name": "${new.template_name}",
|
|
95
|
+
"template_data": "${new.template_data}",
|
|
96
|
+
"attachments": "${new.attachments}",
|
|
97
|
+
"reply_to": "${new.reply_to}",
|
|
98
|
+
"ref_entity": "${new.ref_entity}",
|
|
99
|
+
"ref_seq": "${new.ref_seq}"
|
|
100
|
+
}
|
|
101
|
+
]
|
|
102
|
+
},
|
|
103
|
+
"read_only": true
|
|
104
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "alimtalk_log",
|
|
3
|
+
"description": "알림톡 발송 로그 — 워커가 소비하는 DB 큐 역할을 합니다. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"history": false,
|
|
5
|
+
"read_only": true,
|
|
6
|
+
"compress": true,
|
|
7
|
+
"index": {
|
|
8
|
+
"status": {
|
|
9
|
+
"type": [
|
|
10
|
+
"pending",
|
|
11
|
+
"processing",
|
|
12
|
+
"sent",
|
|
13
|
+
"delivered",
|
|
14
|
+
"failed",
|
|
15
|
+
"expired"
|
|
16
|
+
],
|
|
17
|
+
"default": "pending",
|
|
18
|
+
"comment": "발송 상태 (delivered = 프로바이더 수신 확인)"
|
|
19
|
+
},
|
|
20
|
+
"template_code": {
|
|
21
|
+
"comment": "카카오 알림톡 템플릿 코드",
|
|
22
|
+
"required": true
|
|
23
|
+
},
|
|
24
|
+
"receiver": {
|
|
25
|
+
"comment": "수신자 전화번호",
|
|
26
|
+
"required": true
|
|
27
|
+
},
|
|
28
|
+
"alimtalk_msg_seq": {
|
|
29
|
+
"comment": "alimtalk_msg 참조 seq"
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
"fields": {
|
|
33
|
+
"template_name": { "comment": "내부 템플릿 이름" },
|
|
34
|
+
"variables_json": { "type": "text", "comment": "템플릿 변수 JSON" },
|
|
35
|
+
"provider": { "comment": "사용 프로바이더" },
|
|
36
|
+
"provider_msg_id": { "comment": "프로바이더 메시지 ID" },
|
|
37
|
+
"error_message": { "type": "text", "comment": "오류 메시지" },
|
|
38
|
+
"retry_count": { "type": "uint", "default": 0 },
|
|
39
|
+
"sent_at": { "type": "string" },
|
|
40
|
+
"delivered_at": {
|
|
41
|
+
"type": "string",
|
|
42
|
+
"comment": "프로바이더 수신 확인 시각"
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "alimtalk_msg",
|
|
3
|
+
"description": "알림톡 발송 트리거 엔티티 — Hook 또는 API를 통해 생성되면 알림톡 발송이 시작됩니다. 사용자 환경에 맞게 index·fields를 자유롭게 확장할 수 있습니다.",
|
|
4
|
+
"history": false,
|
|
5
|
+
"index": {
|
|
6
|
+
"template_code": {
|
|
7
|
+
"comment": "카카오 알림톡 템플릿 코드",
|
|
8
|
+
"required": true
|
|
9
|
+
},
|
|
10
|
+
"receiver": {
|
|
11
|
+
"comment": "수신자 전화번호",
|
|
12
|
+
"required": true
|
|
13
|
+
},
|
|
14
|
+
"status": {
|
|
15
|
+
"type": ["pending", "processing", "sent", "delivered", "failed"],
|
|
16
|
+
"default": "pending",
|
|
17
|
+
"comment": "발송 상태 (delivered = 프로바이더 수신 확인)"
|
|
18
|
+
}
|
|
19
|
+
},
|
|
20
|
+
"fields": {
|
|
21
|
+
"variables_json": {
|
|
22
|
+
"type": "text",
|
|
23
|
+
"comment": "템플릿 변수 JSON (#{key} 바인딩)"
|
|
24
|
+
},
|
|
25
|
+
"provider": { "comment": "프로바이더 키 (빈 값이면 default)" },
|
|
26
|
+
"ref_entity": { "comment": "참조 엔티티 이름" },
|
|
27
|
+
"ref_seq": { "type": "int" }
|
|
28
|
+
},
|
|
29
|
+
"hooks": {
|
|
30
|
+
"after_insert": [
|
|
31
|
+
{
|
|
32
|
+
"type": "alimtalk",
|
|
33
|
+
"alimtalk_receiver": "${new.receiver}",
|
|
34
|
+
"alimtalk_template_code": "${new.template_code}",
|
|
35
|
+
"alimtalk_variables": "${new.variables_json}"
|
|
36
|
+
}
|
|
37
|
+
]
|
|
38
|
+
}
|
|
39
|
+
}
|