@sayren/store-sdk 0.18.0 → 0.20.0
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/dist/index.d.mts +1774 -1262
- package/dist/index.mjs +705 -497
- package/package.json +1 -1
- package/src/client.ts +224 -98
- package/src/index.ts +1 -2
- package/src/schemas/claim.ts +1 -1
- package/src/schemas/fulfillment.ts +26 -275
- package/src/schemas/misc.ts +1 -1
- package/src/schemas/order.ts +10 -61
- package/src/schemas/scope.ts +3 -0
- package/src/schemas/store.ts +2 -30
- package/src/schemas/storefront-hosting.ts +841 -0
- package/src/schemas/upload.ts +2 -48
- package/src/schemas/webhook-event.ts +9 -13
- package/src/schemas/digital-asset.ts +0 -65
- package/src/schemas/fulfillment-code.ts +0 -143
package/dist/index.d.mts
CHANGED
|
@@ -165,8 +165,8 @@ export declare const auditLogPageSchema: z.ZodObject<{
|
|
|
165
165
|
}, z.core.$strip>;
|
|
166
166
|
export type AuditLogPage = z.infer<typeof auditLogPageSchema>;
|
|
167
167
|
export declare const agentPolicyDecisionSchema: z.ZodEnum<{
|
|
168
|
-
APPROVAL_REQUIRED: "APPROVAL_REQUIRED";
|
|
169
168
|
DENIED: "DENIED";
|
|
169
|
+
APPROVAL_REQUIRED: "APPROVAL_REQUIRED";
|
|
170
170
|
ALLOW: "ALLOW";
|
|
171
171
|
}>;
|
|
172
172
|
export type AgentPolicyDecision = z.infer<typeof agentPolicyDecisionSchema>;
|
|
@@ -190,8 +190,8 @@ export type WritePreview = z.infer<typeof writePreviewSchema>;
|
|
|
190
190
|
export declare const writeDryRunResultSchema: z.ZodObject<{
|
|
191
191
|
dryRun: z.ZodLiteral<true>;
|
|
192
192
|
decision: z.ZodEnum<{
|
|
193
|
-
APPROVAL_REQUIRED: "APPROVAL_REQUIRED";
|
|
194
193
|
DENIED: "DENIED";
|
|
194
|
+
APPROVAL_REQUIRED: "APPROVAL_REQUIRED";
|
|
195
195
|
ALLOW: "ALLOW";
|
|
196
196
|
}>;
|
|
197
197
|
reason: z.ZodNullable<z.ZodString>;
|
|
@@ -213,25 +213,25 @@ export declare const writeDryRunResultSchema: z.ZodObject<{
|
|
|
213
213
|
}, z.core.$strip>;
|
|
214
214
|
export type WriteDryRunResult = z.infer<typeof writeDryRunResultSchema>;
|
|
215
215
|
export declare const approvalStatusSchema: z.ZodEnum<{
|
|
216
|
-
EXPIRED: "EXPIRED";
|
|
217
216
|
PENDING: "PENDING";
|
|
218
217
|
FAILED: "FAILED";
|
|
219
218
|
SUCCEEDED: "SUCCEEDED";
|
|
220
219
|
EXECUTING: "EXECUTING";
|
|
221
220
|
UNKNOWN: "UNKNOWN";
|
|
222
221
|
REJECTED: "REJECTED";
|
|
222
|
+
EXPIRED: "EXPIRED";
|
|
223
223
|
}>;
|
|
224
224
|
export type ApprovalStatus = z.infer<typeof approvalStatusSchema>;
|
|
225
225
|
export declare const approvalRequestSchema: z.ZodObject<{
|
|
226
226
|
approvalId: z.ZodString;
|
|
227
227
|
status: z.ZodEnum<{
|
|
228
|
-
EXPIRED: "EXPIRED";
|
|
229
228
|
PENDING: "PENDING";
|
|
230
229
|
FAILED: "FAILED";
|
|
231
230
|
SUCCEEDED: "SUCCEEDED";
|
|
232
231
|
EXECUTING: "EXECUTING";
|
|
233
232
|
UNKNOWN: "UNKNOWN";
|
|
234
233
|
REJECTED: "REJECTED";
|
|
234
|
+
EXPIRED: "EXPIRED";
|
|
235
235
|
}>;
|
|
236
236
|
operationId: z.ZodString;
|
|
237
237
|
method: z.ZodString;
|
|
@@ -287,13 +287,13 @@ export declare const approvalRequestSchema: z.ZodObject<{
|
|
|
287
287
|
export type ApprovalRequest = z.infer<typeof approvalRequestSchema>;
|
|
288
288
|
export declare const approvalListQuerySchema: z.ZodObject<{
|
|
289
289
|
status: z.ZodOptional<z.ZodPipe<z.ZodPipe<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]>, z.ZodTransform<string[], string | string[]>>, z.ZodArray<z.ZodEnum<{
|
|
290
|
-
EXPIRED: "EXPIRED";
|
|
291
290
|
PENDING: "PENDING";
|
|
292
291
|
FAILED: "FAILED";
|
|
293
292
|
SUCCEEDED: "SUCCEEDED";
|
|
294
293
|
EXECUTING: "EXECUTING";
|
|
295
294
|
UNKNOWN: "UNKNOWN";
|
|
296
295
|
REJECTED: "REJECTED";
|
|
296
|
+
EXPIRED: "EXPIRED";
|
|
297
297
|
}>>>>;
|
|
298
298
|
cursor: z.ZodOptional<z.ZodString>;
|
|
299
299
|
limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
@@ -306,13 +306,13 @@ export declare const approvalPageSchema: z.ZodObject<{
|
|
|
306
306
|
items: z.ZodArray<z.ZodObject<{
|
|
307
307
|
approvalId: z.ZodString;
|
|
308
308
|
status: z.ZodEnum<{
|
|
309
|
-
EXPIRED: "EXPIRED";
|
|
310
309
|
PENDING: "PENDING";
|
|
311
310
|
FAILED: "FAILED";
|
|
312
311
|
SUCCEEDED: "SUCCEEDED";
|
|
313
312
|
EXECUTING: "EXECUTING";
|
|
314
313
|
UNKNOWN: "UNKNOWN";
|
|
315
314
|
REJECTED: "REJECTED";
|
|
315
|
+
EXPIRED: "EXPIRED";
|
|
316
316
|
}>;
|
|
317
317
|
operationId: z.ZodString;
|
|
318
318
|
method: z.ZodString;
|
|
@@ -1073,9 +1073,9 @@ export type ApiLogSummary = z.infer<typeof apiLogSummarySchema>;
|
|
|
1073
1073
|
//#endregion
|
|
1074
1074
|
//#region src/schemas/auth.d.ts
|
|
1075
1075
|
export declare const storeRoleSchema: z.ZodEnum<{
|
|
1076
|
-
OWNER: "OWNER";
|
|
1077
1076
|
ADMIN: "ADMIN";
|
|
1078
1077
|
STAFF: "STAFF";
|
|
1078
|
+
OWNER: "OWNER";
|
|
1079
1079
|
}>;
|
|
1080
1080
|
export type StoreRole = z.infer<typeof storeRoleSchema>;
|
|
1081
1081
|
export declare const userTokenResponseSchema: z.ZodObject<{
|
|
@@ -1099,9 +1099,9 @@ export declare const storeTokenResponseSchema: z.ZodObject<{
|
|
|
1099
1099
|
expires_in: z.ZodNumber;
|
|
1100
1100
|
storeId: z.ZodString;
|
|
1101
1101
|
role: z.ZodEnum<{
|
|
1102
|
-
OWNER: "OWNER";
|
|
1103
1102
|
ADMIN: "ADMIN";
|
|
1104
1103
|
STAFF: "STAFF";
|
|
1104
|
+
OWNER: "OWNER";
|
|
1105
1105
|
}>;
|
|
1106
1106
|
scopes: z.ZodArray<z.ZodString>;
|
|
1107
1107
|
}, z.core.$strip>;
|
|
@@ -1111,9 +1111,9 @@ export declare const myStoreSchema: z.ZodObject<{
|
|
|
1111
1111
|
storeName: z.ZodString;
|
|
1112
1112
|
storeCode: z.ZodString;
|
|
1113
1113
|
role: z.ZodEnum<{
|
|
1114
|
-
OWNER: "OWNER";
|
|
1115
1114
|
ADMIN: "ADMIN";
|
|
1116
1115
|
STAFF: "STAFF";
|
|
1116
|
+
OWNER: "OWNER";
|
|
1117
1117
|
}>;
|
|
1118
1118
|
status: z.ZodEnum<{
|
|
1119
1119
|
ACTIVE: "ACTIVE";
|
|
@@ -1725,8 +1725,8 @@ export declare const couponStatusSchema: z.ZodEnum<{
|
|
|
1725
1725
|
export type CouponStatus = z.infer<typeof couponStatusSchema>;
|
|
1726
1726
|
/** 지금 만들 수 있는 발급 방식 — 다운로드·가입 자동 지급은 뒤 단계다 */
|
|
1727
1727
|
export declare const couponIssueMethodSchema: z.ZodEnum<{
|
|
1728
|
-
CODE: "CODE";
|
|
1729
1728
|
MANUAL: "MANUAL";
|
|
1729
|
+
CODE: "CODE";
|
|
1730
1730
|
}>;
|
|
1731
1731
|
export type CouponIssueMethod = z.infer<typeof couponIssueMethodSchema>;
|
|
1732
1732
|
/** 코드 형식 — 영문·숫자·`-`·`_` 6~30자. 대소문자를 구분하지 않고 서버가 대문자로 저장한다 */
|
|
@@ -1777,8 +1777,8 @@ export declare const createCouponRequestSchema: z.ZodObject<{
|
|
|
1777
1777
|
excludeCategoryIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1778
1778
|
}, z.core.$strict>>;
|
|
1779
1779
|
issueMethod: z.ZodEnum<{
|
|
1780
|
-
CODE: "CODE";
|
|
1781
1780
|
MANUAL: "MANUAL";
|
|
1781
|
+
CODE: "CODE";
|
|
1782
1782
|
}>;
|
|
1783
1783
|
code: z.ZodOptional<z.ZodString>;
|
|
1784
1784
|
startsAt: z.ZodOptional<z.ZodNullable<z.ZodISODateTime>>;
|
|
@@ -1895,8 +1895,8 @@ export declare const couponListQuerySchema: z.ZodObject<{
|
|
|
1895
1895
|
DELIVERY: "DELIVERY";
|
|
1896
1896
|
}>>;
|
|
1897
1897
|
issueMethod: z.ZodOptional<z.ZodEnum<{
|
|
1898
|
-
CODE: "CODE";
|
|
1899
1898
|
MANUAL: "MANUAL";
|
|
1899
|
+
CODE: "CODE";
|
|
1900
1900
|
}>>;
|
|
1901
1901
|
q: z.ZodOptional<z.ZodString>;
|
|
1902
1902
|
}, z.core.$strip>;
|
|
@@ -2314,180 +2314,6 @@ export declare const customerWithdrawalBlockedDetailsSchema: z.ZodObject<{
|
|
|
2314
2314
|
}, z.core.$strip>;
|
|
2315
2315
|
export type CustomerWithdrawalBlockedDetails = z.infer<typeof customerWithdrawalBlockedDetailsSchema>;
|
|
2316
2316
|
//#endregion
|
|
2317
|
-
//#region src/schemas/digital-asset.d.ts
|
|
2318
|
-
/**
|
|
2319
|
-
* 파일 다운로드 상품의 판매 파일 (이슈 #48 단계 3).
|
|
2320
|
-
*
|
|
2321
|
-
* 파일은 CDN **비공개 객체**다. `POST /v1/uploads`(`purpose: "digital-asset"`)로 자리를 받아 응답의 `headers`와 함께 PUT하고,
|
|
2322
|
-
* 응답의 `key`로 상품에 연결한다. 객체 키와 파일 주소는 어떤 응답에도 싣지 않는다 — 구매자는 제공된 주문상품에서
|
|
2323
|
-
* 수명 300초의 서명 주소로만 받는다. 주문은 주문 시점 파일을 스냅샷하므로 파일을 바꿔도 이미 산 구매자는 옛 파일을 받는다.
|
|
2324
|
-
*/
|
|
2325
|
-
export declare const digitalAssetAttachRequestSchema: z.ZodObject<{
|
|
2326
|
-
key: z.ZodString;
|
|
2327
|
-
fileName: z.ZodString;
|
|
2328
|
-
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
2329
|
-
contentType: z.ZodOptional<z.ZodString>;
|
|
2330
|
-
variantId: z.ZodOptional<z.ZodString>;
|
|
2331
|
-
}, z.core.$strip>;
|
|
2332
|
-
export type DigitalAssetAttachRequest = z.infer<typeof digitalAssetAttachRequestSchema>;
|
|
2333
|
-
/** 판매 파일 — 객체 키·주소는 싣지 않는다 */
|
|
2334
|
-
export declare const digitalAssetSchema: z.ZodObject<{
|
|
2335
|
-
assetId: z.ZodString;
|
|
2336
|
-
productId: z.ZodString;
|
|
2337
|
-
variantId: z.ZodNullable<z.ZodString>;
|
|
2338
|
-
fileName: z.ZodString;
|
|
2339
|
-
contentType: z.ZodNullable<z.ZodString>;
|
|
2340
|
-
sizeBytes: z.ZodNullable<z.ZodNumber>;
|
|
2341
|
-
status: z.ZodString;
|
|
2342
|
-
createdAt: z.ZodString;
|
|
2343
|
-
}, z.core.$strip>;
|
|
2344
|
-
export type DigitalAsset = z.infer<typeof digitalAssetSchema>;
|
|
2345
|
-
/** 셀러 확인용 서명 주소 — `POST /v1/products/{productId}/digital-assets/{assetId}/preview-url` */
|
|
2346
|
-
export declare const digitalAssetPreviewSchema: z.ZodObject<{
|
|
2347
|
-
url: z.ZodURL;
|
|
2348
|
-
expiresAt: z.ZodString;
|
|
2349
|
-
}, z.core.$strip>;
|
|
2350
|
-
export type DigitalAssetPreview = z.infer<typeof digitalAssetPreviewSchema>;
|
|
2351
|
-
/** 주문상품의 다운로드 제공 정보 — 주문 응답의 `fulfillment.download` */
|
|
2352
|
-
export declare const orderItemDownloadSchema: z.ZodObject<{
|
|
2353
|
-
count: z.ZodNumber;
|
|
2354
|
-
limit: z.ZodNumber;
|
|
2355
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2356
|
-
firstDownloadedAt: z.ZodNullable<z.ZodString>;
|
|
2357
|
-
files: z.ZodArray<z.ZodObject<{
|
|
2358
|
-
assetId: z.ZodString;
|
|
2359
|
-
fileName: z.ZodString;
|
|
2360
|
-
sizeBytes: z.ZodNullable<z.ZodNumber>;
|
|
2361
|
-
}, z.core.$strip>>;
|
|
2362
|
-
}, z.core.$strip>;
|
|
2363
|
-
export type OrderItemDownload = z.infer<typeof orderItemDownloadSchema>;
|
|
2364
|
-
//#endregion
|
|
2365
|
-
//#region src/schemas/fulfillment-code.d.ts
|
|
2366
|
-
/**
|
|
2367
|
-
* 코드 발급 상품의 코드 풀 (이슈 #48 단계 2) — 라이선스 키·기프트 코드처럼 결제 확정과 함께 한 개씩 배정하는 코드다.
|
|
2368
|
-
*
|
|
2369
|
-
* **평문 코드는 두 경로로만 나간다** — 구매자 열람(`POST /storefront/v1/me/order-items/{id}/fulfillment/reveal`)과 셀러 콘솔
|
|
2370
|
-
* 열람(`POST /v1/fulfillment-codes/{codeId}/reveal`, 콘솔 전용). 목록·주문·웹훅·API 로그에는 가린 값(`hint`)만 싣는다.
|
|
2371
|
-
* 코드는 결제 자격 증명과 같은 키링·AES-256-GCM으로 암호화해 저장한다.
|
|
2372
|
-
*/
|
|
2373
|
-
/**
|
|
2374
|
-
* 코드 상태.
|
|
2375
|
-
* - `AVAILABLE` 판매 가능 — 재고로 센다
|
|
2376
|
-
* - `ASSIGNED` 주문상품에 배정됨
|
|
2377
|
-
* - `REVOKED` 환불로 회수됨(구매자 화면에서 숨긴다. 코드 자체의 무효화는 셀러 시스템 몫이다)
|
|
2378
|
-
* - `EXPIRED` 유효기간이 지나 배정하지 않음
|
|
2379
|
-
* - `VOID` 셀러가 폐기함
|
|
2380
|
-
*/
|
|
2381
|
-
export declare const fulfillmentCodeStatusSchema: z.ZodEnum<{
|
|
2382
|
-
REVOKED: "REVOKED";
|
|
2383
|
-
AVAILABLE: "AVAILABLE";
|
|
2384
|
-
ASSIGNED: "ASSIGNED";
|
|
2385
|
-
EXPIRED: "EXPIRED";
|
|
2386
|
-
VOID: "VOID";
|
|
2387
|
-
}>;
|
|
2388
|
-
export type FulfillmentCodeStatus = z.infer<typeof fulfillmentCodeStatusSchema>;
|
|
2389
|
-
/** 한 번에 올릴 수 있는 코드 수 */
|
|
2390
|
-
export declare const MAX_CODES_PER_UPLOAD = 10000;
|
|
2391
|
-
/** 코드 한 개의 최대 길이 */
|
|
2392
|
-
export declare const MAX_CODE_LENGTH = 200;
|
|
2393
|
-
/**
|
|
2394
|
-
* 코드 일괄 업로드 요청 — `POST /v1/products/{productId}/codes`. `codes`(배열)와 `csv`(본문) 중 하나를 보낸다.
|
|
2395
|
-
* 앞뒤 공백은 지우고 빈 줄은 건너뛴다. 같은 상품에 이미 있는 코드와 요청 안의 중복은 받지 않는다(`duplicates`).
|
|
2396
|
-
*/
|
|
2397
|
-
export declare const fulfillmentCodeUploadRequestSchema: z.ZodObject<{
|
|
2398
|
-
variantId: z.ZodOptional<z.ZodString>;
|
|
2399
|
-
codes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2400
|
-
csv: z.ZodOptional<z.ZodString>;
|
|
2401
|
-
expiresAt: z.ZodOptional<z.ZodISODateTime>;
|
|
2402
|
-
}, z.core.$strip>;
|
|
2403
|
-
export type FulfillmentCodeUploadRequest = z.infer<typeof fulfillmentCodeUploadRequestSchema>;
|
|
2404
|
-
/** 받지 않은 줄 */
|
|
2405
|
-
export declare const fulfillmentCodeRejectionSchema: z.ZodObject<{
|
|
2406
|
-
line: z.ZodNumber;
|
|
2407
|
-
reason: z.ZodString;
|
|
2408
|
-
}, z.core.$strip>;
|
|
2409
|
-
/** 업로드 결과 — 배치 요약 */
|
|
2410
|
-
export declare const fulfillmentCodeBatchSchema: z.ZodObject<{
|
|
2411
|
-
batchId: z.ZodString;
|
|
2412
|
-
productId: z.ZodString;
|
|
2413
|
-
variantId: z.ZodString;
|
|
2414
|
-
total: z.ZodNumber;
|
|
2415
|
-
accepted: z.ZodNumber;
|
|
2416
|
-
duplicates: z.ZodNumber;
|
|
2417
|
-
rejected: z.ZodArray<z.ZodObject<{
|
|
2418
|
-
line: z.ZodNumber;
|
|
2419
|
-
reason: z.ZodString;
|
|
2420
|
-
}, z.core.$strip>>;
|
|
2421
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2422
|
-
createdAt: z.ZodString;
|
|
2423
|
-
}, z.core.$strip>;
|
|
2424
|
-
export type FulfillmentCodeBatch = z.infer<typeof fulfillmentCodeBatchSchema>;
|
|
2425
|
-
/** 코드 목록의 한 줄 — **가린 값만** 싣는다 */
|
|
2426
|
-
export declare const fulfillmentCodeSchema: z.ZodObject<{
|
|
2427
|
-
codeId: z.ZodString;
|
|
2428
|
-
productId: z.ZodString;
|
|
2429
|
-
variantId: z.ZodString;
|
|
2430
|
-
batchId: z.ZodNullable<z.ZodString>;
|
|
2431
|
-
hint: z.ZodString;
|
|
2432
|
-
status: z.ZodString;
|
|
2433
|
-
orderItemId: z.ZodNullable<z.ZodString>;
|
|
2434
|
-
assignedAt: z.ZodNullable<z.ZodString>;
|
|
2435
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
2436
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2437
|
-
createdAt: z.ZodString;
|
|
2438
|
-
}, z.core.$strip>;
|
|
2439
|
-
export type FulfillmentCode = z.infer<typeof fulfillmentCodeSchema>;
|
|
2440
|
-
export declare const fulfillmentCodePageSchema: z.ZodObject<{
|
|
2441
|
-
page: z.ZodNumber;
|
|
2442
|
-
size: z.ZodNumber;
|
|
2443
|
-
totalElements: z.ZodNumber;
|
|
2444
|
-
totalPages: z.ZodNumber;
|
|
2445
|
-
contents: z.ZodArray<z.ZodObject<{
|
|
2446
|
-
codeId: z.ZodString;
|
|
2447
|
-
productId: z.ZodString;
|
|
2448
|
-
variantId: z.ZodString;
|
|
2449
|
-
batchId: z.ZodNullable<z.ZodString>;
|
|
2450
|
-
hint: z.ZodString;
|
|
2451
|
-
status: z.ZodString;
|
|
2452
|
-
orderItemId: z.ZodNullable<z.ZodString>;
|
|
2453
|
-
assignedAt: z.ZodNullable<z.ZodString>;
|
|
2454
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
2455
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2456
|
-
createdAt: z.ZodString;
|
|
2457
|
-
}, z.core.$strip>>;
|
|
2458
|
-
available: z.ZodNumber;
|
|
2459
|
-
}, z.core.$strip>;
|
|
2460
|
-
export type FulfillmentCodePage = z.infer<typeof fulfillmentCodePageSchema>;
|
|
2461
|
-
/** `GET /v1/products/{productId}/codes` 쿼리 */
|
|
2462
|
-
export declare const fulfillmentCodeListQuerySchema: z.ZodObject<{
|
|
2463
|
-
page: z.ZodOptional<z.ZodString>;
|
|
2464
|
-
size: z.ZodOptional<z.ZodString>;
|
|
2465
|
-
status: z.ZodOptional<z.ZodEnum<{
|
|
2466
|
-
REVOKED: "REVOKED";
|
|
2467
|
-
AVAILABLE: "AVAILABLE";
|
|
2468
|
-
ASSIGNED: "ASSIGNED";
|
|
2469
|
-
EXPIRED: "EXPIRED";
|
|
2470
|
-
VOID: "VOID";
|
|
2471
|
-
}>>;
|
|
2472
|
-
variantId: z.ZodOptional<z.ZodString>;
|
|
2473
|
-
batchId: z.ZodOptional<z.ZodString>;
|
|
2474
|
-
orderItemId: z.ZodOptional<z.ZodString>;
|
|
2475
|
-
}, z.core.$strip>;
|
|
2476
|
-
/** 셀러 콘솔 코드 열람 응답 — `POST /v1/fulfillment-codes/{codeId}/reveal` */
|
|
2477
|
-
export declare const fulfillmentCodeRevealSchema: z.ZodObject<{
|
|
2478
|
-
codeId: z.ZodString;
|
|
2479
|
-
code: z.ZodString;
|
|
2480
|
-
}, z.core.$strip>;
|
|
2481
|
-
export type FulfillmentCodeReveal = z.infer<typeof fulfillmentCodeRevealSchema>;
|
|
2482
|
-
/** 주문상품에 배정된 코드의 가린 값 — 주문 응답의 `fulfillment.codes` */
|
|
2483
|
-
export declare const orderItemCodeSchema: z.ZodObject<{
|
|
2484
|
-
codeId: z.ZodString;
|
|
2485
|
-
hint: z.ZodString;
|
|
2486
|
-
status: z.ZodString;
|
|
2487
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
2488
|
-
}, z.core.$strip>;
|
|
2489
|
-
export type OrderItemCode = z.infer<typeof orderItemCodeSchema>;
|
|
2490
|
-
//#endregion
|
|
2491
2317
|
//#region src/schemas/login.d.ts
|
|
2492
2318
|
/** 소셜 로그인 공급자 */
|
|
2493
2319
|
export declare const loginProviderSchema: z.ZodEnum<{
|
|
@@ -3152,65 +2978,45 @@ export type ReviewReportResult = z.infer<typeof reviewReportResultSchema>;
|
|
|
3152
2978
|
//#endregion
|
|
3153
2979
|
//#region src/schemas/fulfillment.d.ts
|
|
3154
2980
|
/**
|
|
3155
|
-
* 상품
|
|
2981
|
+
* 상품 유형 (이슈 #48·#57) — 배송이 필요한 상품과 필요 없는 상품을 가르는 축이다.
|
|
3156
2982
|
*
|
|
3157
|
-
* **상품 유형은
|
|
2983
|
+
* **상품 유형은 이행 방식 하나로 표현한다.** `fulfillment.type`이 배송 필요 여부, 이행 흐름, 클레임 규칙을 정한다.
|
|
3158
2984
|
* 코드 곳곳에서 유형 이름으로 분기하지 않고 이 파일의 판정 함수(`requiresShipping`·`fulfillmentRuleOf`)를 지난다.
|
|
3159
|
-
* 유형이 늘어나도 판정표 한 곳만 고치면 배송비 계산·결제 시작·클레임·콘솔 버튼이 같이 따라온다.
|
|
3160
2985
|
*
|
|
3161
2986
|
* 주문상품 상태 enum은 바꾸지 않는다. 비실물의 **제공 완료는 `DELIVERED`를 재사용한다** — 새 상태를 더하면 기존 소비자의
|
|
3162
|
-
* 상태 분기(배송완료 뒤 구매확정 대기, 반품 가능 판정)가 새 값을 모른다. 표시는
|
|
2987
|
+
* 상태 분기(배송완료 뒤 구매확정 대기, 반품 가능 판정)가 새 값을 모른다. 표시는 유형으로 가른다.
|
|
3163
2988
|
*/
|
|
3164
2989
|
/**
|
|
3165
2990
|
* 상품 유형.
|
|
3166
|
-
* - `SHIPPING` 배송
|
|
3167
|
-
* - `
|
|
3168
|
-
*
|
|
3169
|
-
* -
|
|
3170
|
-
*
|
|
2991
|
+
* - `SHIPPING` 배송 상품. 택배로 발송하고 송장·배송 추적으로 배송완료가 된다
|
|
2992
|
+
* - `MANUAL` 배송 없는 상품(비실물). 셀러가 제공 처리(`POST /v1/order-items/{orderItemId}/fulfill`)로 제공 완료를 기록한다
|
|
2993
|
+
*
|
|
2994
|
+
* 비실물의 세부 구분(파일 다운로드·코드 발급·이용권·방문 수령)은 2026-09-28에 제품에서 뺐다(이슈 #48 범위 축소).
|
|
2995
|
+
* 이름은 이행 방식이다 — `SHIPPING`이 택배 발송이듯 `MANUAL`은 셀러가 직접 제공한다는 뜻이다.
|
|
3171
2996
|
*/
|
|
3172
2997
|
export declare const fulfillmentTypeSchema: z.ZodEnum<{
|
|
3173
2998
|
SHIPPING: "SHIPPING";
|
|
3174
|
-
DOWNLOAD: "DOWNLOAD";
|
|
3175
|
-
CODE: "CODE";
|
|
3176
|
-
SERVICE: "SERVICE";
|
|
3177
|
-
PICKUP: "PICKUP";
|
|
3178
|
-
}>;
|
|
3179
|
-
export type FulfillmentType = z.infer<typeof fulfillmentTypeSchema>;
|
|
3180
|
-
/** 제공 방식 — `AUTO`는 결제 확정과 함께 제공하고, `MANUAL`은 셀러가 제공 처리한다 */
|
|
3181
|
-
export declare const fulfillmentModeSchema: z.ZodEnum<{
|
|
3182
|
-
AUTO: "AUTO";
|
|
3183
2999
|
MANUAL: "MANUAL";
|
|
3184
3000
|
}>;
|
|
3185
|
-
export type
|
|
3001
|
+
export type FulfillmentType = z.infer<typeof fulfillmentTypeSchema>;
|
|
3186
3002
|
/**
|
|
3187
3003
|
* 응답 스키마용 유형 — 서버가 나중에 유형을 더해도 옛 SDK가 응답 파싱에서 깨지지 않게 문자열로 받는다.
|
|
3188
3004
|
* 요청은 `fulfillmentTypeSchema`(닫힌 enum)로 검증한다.
|
|
3189
3005
|
*/
|
|
3190
3006
|
export declare const fulfillmentTypeResponseSchema: z.ZodString;
|
|
3191
|
-
/** 유형 하나의 규칙 —
|
|
3007
|
+
/** 유형 하나의 규칙 — 배송·클레임이 이 표를 읽는다 */
|
|
3192
3008
|
export interface FulfillmentRule {
|
|
3193
3009
|
/** 택배 배송이 필요한가 — 배송비·배송지·발송 흐름의 대상인가 */
|
|
3194
3010
|
requiresShipping: boolean;
|
|
3195
|
-
/**
|
|
3196
|
-
modes: readonly FulfillmentMode[];
|
|
3197
|
-
/** 제공 방식을 정하지 않았을 때의 기본값. 배송 상품은 null */
|
|
3198
|
-
defaultMode: FulfillmentMode | null;
|
|
3199
|
-
/** 반품에 수거가 필요한가 — 실물만 수거한다(방문 수령 포함) */
|
|
3011
|
+
/** 반품에 수거가 필요한가 — 실물만 수거한다 */
|
|
3200
3012
|
requiresCollection: boolean;
|
|
3201
3013
|
/** 교환을 받는가 — 실물만 받는다 */
|
|
3202
3014
|
exchangeSupported: boolean;
|
|
3203
3015
|
}
|
|
3204
|
-
/**
|
|
3205
|
-
* 유형별 규칙표 — **유일한 원천이다.**
|
|
3206
|
-
*
|
|
3207
|
-
* `PICKUP`은 실물이라 반품 수거와 교환을 받지만 택배 배송은 없다. `DOWNLOAD`는 결제 즉시 권한을 발급하므로 `AUTO`만,
|
|
3208
|
-
* `PICKUP`은 셀러가 수령 완료를 누르므로 `MANUAL`만 둔다.
|
|
3209
|
-
*/
|
|
3016
|
+
/** 유형별 규칙표 — **유일한 원천이다.** */
|
|
3210
3017
|
export declare const FULFILLMENT_RULES: Readonly<Record<FulfillmentType, FulfillmentRule>>;
|
|
3211
3018
|
/**
|
|
3212
|
-
* 저장된 값 → 유형. null·모르는 값은 `SHIPPING`이다 — 이 필드 이전의
|
|
3213
|
-
* 상품은 모두 배송 상품이었다.
|
|
3019
|
+
* 저장된 값 → 유형. null·모르는 값은 `SHIPPING`이다 — 이 필드 이전의 상품·주문상품은 모두 배송 상품이었다.
|
|
3214
3020
|
*/
|
|
3215
3021
|
export declare function fulfillmentTypeOf(value: string | null | undefined): FulfillmentType;
|
|
3216
3022
|
/** 유형의 규칙 — 모르는 값은 배송 상품 규칙이다 */
|
|
@@ -3219,11 +3025,6 @@ export declare function fulfillmentRuleOf(type: string | null | undefined): Fulf
|
|
|
3219
3025
|
export declare function requiresShipping(type: string | null | undefined): boolean;
|
|
3220
3026
|
/** 반품에 수거가 필요한가 — 비실물 반품은 수거 등록·수거 완료 없이 승인한다 */
|
|
3221
3027
|
export declare function requiresCollection(type: string | null | undefined): boolean;
|
|
3222
|
-
/**
|
|
3223
|
-
* 유효 제공 방식 — 요청 값이 유형에 허용되면 그 값, 생략이면 유형 기본값이다. 배송 상품은 null이다.
|
|
3224
|
-
* 허용되지 않는 값은 `null`을 돌려주지 않고 호출부가 거부하도록 `undefined`를 돌려준다.
|
|
3225
|
-
*/
|
|
3226
|
-
export declare function resolveFulfillmentMode(type: FulfillmentType, mode: FulfillmentMode | null | undefined): FulfillmentMode | null | undefined;
|
|
3227
3028
|
/**
|
|
3228
3029
|
* 배송이 없는 주문상품의 배송 묶음 키 (`order_items.delivery_bundle_key`).
|
|
3229
3030
|
*
|
|
@@ -3239,13 +3040,8 @@ export declare const deliveryTypeSchema: z.ZodEnum<{
|
|
|
3239
3040
|
CONDITIONAL_FREE: "CONDITIONAL_FREE";
|
|
3240
3041
|
}>;
|
|
3241
3042
|
export type DeliveryType = z.infer<typeof deliveryTypeSchema>;
|
|
3242
|
-
/** 파일 다운로드 기본값 — 횟수 5회·기간 30일(#48 결정 8) */
|
|
3243
|
-
export declare const DOWNLOAD_DEFAULTS: {
|
|
3244
|
-
readonly limit: 5;
|
|
3245
|
-
readonly days: 30;
|
|
3246
|
-
};
|
|
3247
3043
|
/**
|
|
3248
|
-
* 상품 이행 — 등록(POST).
|
|
3044
|
+
* 상품 이행 — 등록(POST). 배송 상품의 `shipping`을 생략하면 기본값(유료 배송·스토어 기본 배송비·기본 출고지·반품지)이다.
|
|
3249
3045
|
*/
|
|
3250
3046
|
export declare const productFulfillmentCreateSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
3251
3047
|
type: z.ZodLiteral<"SHIPPING">;
|
|
@@ -3261,35 +3057,7 @@ export declare const productFulfillmentCreateSchema: z.ZodDiscriminatedUnion<[z.
|
|
|
3261
3057
|
returnAddressId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
3262
3058
|
}, z.core.$strict>>;
|
|
3263
3059
|
}, z.core.$strict>, z.ZodObject<{
|
|
3264
|
-
type: z.ZodLiteral<"
|
|
3265
|
-
download: z.ZodDefault<z.ZodObject<{
|
|
3266
|
-
limit: z.ZodDefault<z.ZodNumber>;
|
|
3267
|
-
days: z.ZodDefault<z.ZodNumber>;
|
|
3268
|
-
stockTracking: z.ZodDefault<z.ZodBoolean>;
|
|
3269
|
-
withdrawalRestricted: z.ZodDefault<z.ZodBoolean>;
|
|
3270
|
-
}, z.core.$strict>>;
|
|
3271
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
3272
|
-
type: z.ZodLiteral<"CODE">;
|
|
3273
|
-
code: z.ZodDefault<z.ZodObject<{
|
|
3274
|
-
mode: z.ZodDefault<z.ZodEnum<{
|
|
3275
|
-
AUTO: "AUTO";
|
|
3276
|
-
MANUAL: "MANUAL";
|
|
3277
|
-
}>>;
|
|
3278
|
-
withdrawalRestricted: z.ZodDefault<z.ZodBoolean>;
|
|
3279
|
-
}, z.core.$strict>>;
|
|
3280
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
3281
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3282
|
-
service: z.ZodDefault<z.ZodObject<{
|
|
3283
|
-
mode: z.ZodDefault<z.ZodEnum<{
|
|
3284
|
-
AUTO: "AUTO";
|
|
3285
|
-
MANUAL: "MANUAL";
|
|
3286
|
-
}>>;
|
|
3287
|
-
}, z.core.$strict>>;
|
|
3288
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
3289
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3290
|
-
pickup: z.ZodDefault<z.ZodObject<{
|
|
3291
|
-
addressId: z.ZodOptional<z.ZodString>;
|
|
3292
|
-
}, z.core.$strict>>;
|
|
3060
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3293
3061
|
}, z.core.$strict>], "type">;
|
|
3294
3062
|
export type ProductFulfillmentCreate = z.infer<typeof productFulfillmentCreateSchema>;
|
|
3295
3063
|
/** 등록 요청의 입력 모양 — 기본값이 채워지기 전(생략 가능한 필드가 optional) */
|
|
@@ -3312,35 +3080,7 @@ export declare const productFulfillmentUpdateSchema: z.ZodDiscriminatedUnion<[z.
|
|
|
3312
3080
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3313
3081
|
}, z.core.$strict>;
|
|
3314
3082
|
}, z.core.$strict>, z.ZodObject<{
|
|
3315
|
-
type: z.ZodLiteral<"
|
|
3316
|
-
download: z.ZodObject<{
|
|
3317
|
-
limit: z.ZodNumber;
|
|
3318
|
-
days: z.ZodNumber;
|
|
3319
|
-
stockTracking: z.ZodBoolean;
|
|
3320
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3321
|
-
}, z.core.$strict>;
|
|
3322
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
3323
|
-
type: z.ZodLiteral<"CODE">;
|
|
3324
|
-
code: z.ZodObject<{
|
|
3325
|
-
mode: z.ZodEnum<{
|
|
3326
|
-
AUTO: "AUTO";
|
|
3327
|
-
MANUAL: "MANUAL";
|
|
3328
|
-
}>;
|
|
3329
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3330
|
-
}, z.core.$strict>;
|
|
3331
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
3332
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3333
|
-
service: z.ZodObject<{
|
|
3334
|
-
mode: z.ZodEnum<{
|
|
3335
|
-
AUTO: "AUTO";
|
|
3336
|
-
MANUAL: "MANUAL";
|
|
3337
|
-
}>;
|
|
3338
|
-
}, z.core.$strict>;
|
|
3339
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
3340
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3341
|
-
pickup: z.ZodObject<{
|
|
3342
|
-
addressId: z.ZodString;
|
|
3343
|
-
}, z.core.$strict>;
|
|
3083
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3344
3084
|
}, z.core.$strict>], "type">;
|
|
3345
3085
|
export type ProductFulfillmentUpdate = z.infer<typeof productFulfillmentUpdateSchema>;
|
|
3346
3086
|
/**
|
|
@@ -3361,35 +3101,7 @@ export declare const productFulfillmentSchema: z.ZodDiscriminatedUnion<[z.ZodObj
|
|
|
3361
3101
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3362
3102
|
}, z.core.$strip>;
|
|
3363
3103
|
}, z.core.$strip>, z.ZodObject<{
|
|
3364
|
-
type: z.ZodLiteral<"
|
|
3365
|
-
download: z.ZodObject<{
|
|
3366
|
-
limit: z.ZodNumber;
|
|
3367
|
-
days: z.ZodNumber;
|
|
3368
|
-
stockTracking: z.ZodBoolean;
|
|
3369
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3370
|
-
}, z.core.$strip>;
|
|
3371
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3372
|
-
type: z.ZodLiteral<"CODE">;
|
|
3373
|
-
code: z.ZodObject<{
|
|
3374
|
-
mode: z.ZodEnum<{
|
|
3375
|
-
AUTO: "AUTO";
|
|
3376
|
-
MANUAL: "MANUAL";
|
|
3377
|
-
}>;
|
|
3378
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3379
|
-
}, z.core.$strip>;
|
|
3380
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3381
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3382
|
-
service: z.ZodObject<{
|
|
3383
|
-
mode: z.ZodEnum<{
|
|
3384
|
-
AUTO: "AUTO";
|
|
3385
|
-
MANUAL: "MANUAL";
|
|
3386
|
-
}>;
|
|
3387
|
-
}, z.core.$strip>;
|
|
3388
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3389
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3390
|
-
pickup: z.ZodObject<{
|
|
3391
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
3392
|
-
}, z.core.$strip>;
|
|
3104
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3393
3105
|
}, z.core.$strip>], "type">;
|
|
3394
3106
|
export type ProductFulfillment = z.infer<typeof productFulfillmentSchema>;
|
|
3395
3107
|
/** 유형 이름 → 그 유형의 저장된 이행 */
|
|
@@ -3428,35 +3140,7 @@ export declare const productFulfillmentResponseSchema: z.ZodUnion<readonly [z.Zo
|
|
|
3428
3140
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3429
3141
|
}, z.core.$strip>;
|
|
3430
3142
|
}, z.core.$strip>, z.ZodObject<{
|
|
3431
|
-
type: z.ZodLiteral<"
|
|
3432
|
-
download: z.ZodObject<{
|
|
3433
|
-
limit: z.ZodNumber;
|
|
3434
|
-
days: z.ZodNumber;
|
|
3435
|
-
stockTracking: z.ZodBoolean;
|
|
3436
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3437
|
-
}, z.core.$strip>;
|
|
3438
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3439
|
-
type: z.ZodLiteral<"CODE">;
|
|
3440
|
-
code: z.ZodObject<{
|
|
3441
|
-
mode: z.ZodEnum<{
|
|
3442
|
-
AUTO: "AUTO";
|
|
3443
|
-
MANUAL: "MANUAL";
|
|
3444
|
-
}>;
|
|
3445
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3446
|
-
}, z.core.$strip>;
|
|
3447
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3448
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3449
|
-
service: z.ZodObject<{
|
|
3450
|
-
mode: z.ZodEnum<{
|
|
3451
|
-
AUTO: "AUTO";
|
|
3452
|
-
MANUAL: "MANUAL";
|
|
3453
|
-
}>;
|
|
3454
|
-
}, z.core.$strip>;
|
|
3455
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3456
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3457
|
-
pickup: z.ZodObject<{
|
|
3458
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
3459
|
-
}, z.core.$strip>;
|
|
3143
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3460
3144
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
3461
3145
|
type: z.ZodString;
|
|
3462
3146
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -3464,21 +3148,9 @@ export declare const productFulfillmentResponseSchema: z.ZodUnion<readonly [z.Zo
|
|
|
3464
3148
|
type: string;
|
|
3465
3149
|
}>>]>;
|
|
3466
3150
|
export type ProductFulfillmentView = z.infer<typeof productFulfillmentResponseSchema>;
|
|
3467
|
-
/** 제공 방식 — CODE·SERVICE는 저장된 값, DOWNLOAD는 AUTO, PICKUP은 MANUAL, 배송 상품은 null */
|
|
3468
|
-
export declare function fulfillmentModeOf(fulfillment: ProductFulfillment): FulfillmentMode | null;
|
|
3469
|
-
/** 재고를 세는가 — 파일 다운로드만 끌 수 있다 */
|
|
3470
|
-
export declare function stockTrackingOf(fulfillment: ProductFulfillment): boolean;
|
|
3471
|
-
/** 청약철회 제한 대상인가 — 파일 다운로드·코드 발급만 켤 수 있다(전자상거래법 제17조 제2항 제5호, 디지털 콘텐츠) */
|
|
3472
|
-
export declare function withdrawalRestrictedOf(fulfillment: ProductFulfillment): boolean;
|
|
3473
|
-
/** 코드 풀을 쓰는가 — 코드 발급 + 자동 제공. 재고가 판매 가능 코드 수다 */
|
|
3474
|
-
export declare function usesCodePool(fulfillment: ProductFulfillment): boolean;
|
|
3475
|
-
/** 결제 확정과 함께 제공까지 끝내는가 — 비실물 + 자동 제공 */
|
|
3476
|
-
export declare function autoFulfillableOf(fulfillment: ProductFulfillment): boolean;
|
|
3477
3151
|
/**
|
|
3478
3152
|
* 주문상품의 주문 시점 이행 — 결제 확정이 주문서 줄에서 굳힌다. 상품의 현재 값이 아니다. 서버는 주문상품 컬럼
|
|
3479
|
-
* (`fulfillment_type`·`delivery_bundle_key
|
|
3480
|
-
*
|
|
3481
|
-
* `mode`는 **주문 시점 상품의 방식**이다. 실제 제공 방식은 제공 기록(`fulfillment.mode`)에 있고 다를 수 있다(자동 제공 상품의 수동 복구).
|
|
3153
|
+
* (`fulfillment_type`·`delivery_bundle_key`)과 jsonb(`fulfillment_snapshot`)를 합쳐 이 모양을 만든다.
|
|
3482
3154
|
*/
|
|
3483
3155
|
export declare const orderItemFulfillmentSnapshotSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
3484
3156
|
type: z.ZodLiteral<"SHIPPING">;
|
|
@@ -3487,29 +3159,7 @@ export declare const orderItemFulfillmentSnapshotSchema: z.ZodDiscriminatedUnion
|
|
|
3487
3159
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3488
3160
|
}, z.core.$strip>;
|
|
3489
3161
|
}, z.core.$strip>, z.ZodObject<{
|
|
3490
|
-
type: z.ZodLiteral<"
|
|
3491
|
-
download: z.ZodObject<{
|
|
3492
|
-
limit: z.ZodNumber;
|
|
3493
|
-
days: z.ZodNumber;
|
|
3494
|
-
stockTracked: z.ZodBoolean;
|
|
3495
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3496
|
-
}, z.core.$strip>;
|
|
3497
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3498
|
-
type: z.ZodLiteral<"CODE">;
|
|
3499
|
-
code: z.ZodObject<{
|
|
3500
|
-
mode: z.ZodString;
|
|
3501
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3502
|
-
}, z.core.$strip>;
|
|
3503
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3504
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3505
|
-
service: z.ZodObject<{
|
|
3506
|
-
mode: z.ZodString;
|
|
3507
|
-
}, z.core.$strip>;
|
|
3508
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3509
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3510
|
-
pickup: z.ZodObject<{
|
|
3511
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
3512
|
-
}, z.core.$strip>;
|
|
3162
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3513
3163
|
}, z.core.$strip>], "type">;
|
|
3514
3164
|
export type OrderItemFulfillmentSnapshot = z.infer<typeof orderItemFulfillmentSnapshotSchema>;
|
|
3515
3165
|
export declare const orderItemFulfillmentSnapshotResponseSchema: z.ZodUnion<readonly [z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
@@ -3519,29 +3169,7 @@ export declare const orderItemFulfillmentSnapshotResponseSchema: z.ZodUnion<read
|
|
|
3519
3169
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3520
3170
|
}, z.core.$strip>;
|
|
3521
3171
|
}, z.core.$strip>, z.ZodObject<{
|
|
3522
|
-
type: z.ZodLiteral<"
|
|
3523
|
-
download: z.ZodObject<{
|
|
3524
|
-
limit: z.ZodNumber;
|
|
3525
|
-
days: z.ZodNumber;
|
|
3526
|
-
stockTracked: z.ZodBoolean;
|
|
3527
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3528
|
-
}, z.core.$strip>;
|
|
3529
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3530
|
-
type: z.ZodLiteral<"CODE">;
|
|
3531
|
-
code: z.ZodObject<{
|
|
3532
|
-
mode: z.ZodString;
|
|
3533
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3534
|
-
}, z.core.$strip>;
|
|
3535
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3536
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3537
|
-
service: z.ZodObject<{
|
|
3538
|
-
mode: z.ZodString;
|
|
3539
|
-
}, z.core.$strip>;
|
|
3540
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3541
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3542
|
-
pickup: z.ZodObject<{
|
|
3543
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
3544
|
-
}, z.core.$strip>;
|
|
3172
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3545
3173
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
3546
3174
|
type: z.ZodString;
|
|
3547
3175
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -3580,40 +3208,13 @@ export declare const shippingAddressSchema: z.ZodObject<{
|
|
|
3580
3208
|
entranceCode: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
3581
3209
|
}, z.core.$strip>;
|
|
3582
3210
|
export type ShippingAddress = z.infer<typeof shippingAddressSchema>;
|
|
3583
|
-
/**
|
|
3211
|
+
/** 배송 없는 주문상품(`MANUAL`)의 제공 기록 (이슈 #48) — 셀러의 제공 처리가 만든다 */
|
|
3584
3212
|
export declare const orderItemFulfillmentSchema: z.ZodObject<{
|
|
3585
3213
|
status: z.ZodString;
|
|
3586
|
-
mode: z.ZodNullable<z.ZodString>;
|
|
3587
3214
|
fulfilledAt: z.ZodString;
|
|
3588
3215
|
note: z.ZodNullable<z.ZodString>;
|
|
3589
|
-
|
|
3590
|
-
codeId: z.ZodString;
|
|
3591
|
-
hint: z.ZodString;
|
|
3592
|
-
status: z.ZodString;
|
|
3593
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
3594
|
-
}, z.core.$strip>>>>;
|
|
3595
|
-
download: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3596
|
-
count: z.ZodNumber;
|
|
3597
|
-
limit: z.ZodNumber;
|
|
3598
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
3599
|
-
firstDownloadedAt: z.ZodNullable<z.ZodString>;
|
|
3600
|
-
files: z.ZodArray<z.ZodObject<{
|
|
3601
|
-
assetId: z.ZodString;
|
|
3602
|
-
fileName: z.ZodString;
|
|
3603
|
-
sizeBytes: z.ZodNullable<z.ZodNumber>;
|
|
3604
|
-
}, z.core.$strip>>;
|
|
3605
|
-
}, z.core.$strip>>>>;
|
|
3606
|
-
mail: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3607
|
-
status: z.ZodString;
|
|
3608
|
-
sentAt: z.ZodNullable<z.ZodString>;
|
|
3609
|
-
errorCode: z.ZodNullable<z.ZodString>;
|
|
3610
|
-
}, z.core.$strip>>>>;
|
|
3216
|
+
mode: z.ZodOptional<z.ZodString>;
|
|
3611
3217
|
}, z.core.$strip>;
|
|
3612
|
-
/** 제공 안내 메일 재발송 결과 */
|
|
3613
|
-
export declare const fulfillmentMailResendSchema: z.ZodObject<{
|
|
3614
|
-
mailStatus: z.ZodString;
|
|
3615
|
-
}, z.core.$strip>;
|
|
3616
|
-
export type FulfillmentMailResend = z.infer<typeof fulfillmentMailResendSchema>;
|
|
3617
3218
|
export type OrderItemFulfillment = z.infer<typeof orderItemFulfillmentSchema>;
|
|
3618
3219
|
export declare const orderItemSchema: z.ZodObject<{
|
|
3619
3220
|
orderItemId: z.ZodString;
|
|
@@ -3645,29 +3246,7 @@ export declare const orderItemSchema: z.ZodObject<{
|
|
|
3645
3246
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3646
3247
|
}, z.core.$strip>;
|
|
3647
3248
|
}, z.core.$strip>, z.ZodObject<{
|
|
3648
|
-
type: z.ZodLiteral<"
|
|
3649
|
-
download: z.ZodObject<{
|
|
3650
|
-
limit: z.ZodNumber;
|
|
3651
|
-
days: z.ZodNumber;
|
|
3652
|
-
stockTracked: z.ZodBoolean;
|
|
3653
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3654
|
-
}, z.core.$strip>;
|
|
3655
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3656
|
-
type: z.ZodLiteral<"CODE">;
|
|
3657
|
-
code: z.ZodObject<{
|
|
3658
|
-
mode: z.ZodString;
|
|
3659
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3660
|
-
}, z.core.$strip>;
|
|
3661
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3662
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3663
|
-
service: z.ZodObject<{
|
|
3664
|
-
mode: z.ZodString;
|
|
3665
|
-
}, z.core.$strip>;
|
|
3666
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3667
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3668
|
-
pickup: z.ZodObject<{
|
|
3669
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
3670
|
-
}, z.core.$strip>;
|
|
3249
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3671
3250
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
3672
3251
|
type: z.ZodString;
|
|
3673
3252
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -3687,31 +3266,9 @@ export declare const orderItemSchema: z.ZodObject<{
|
|
|
3687
3266
|
}, z.core.$strip>>;
|
|
3688
3267
|
fulfillment: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3689
3268
|
status: z.ZodString;
|
|
3690
|
-
mode: z.ZodNullable<z.ZodString>;
|
|
3691
3269
|
fulfilledAt: z.ZodString;
|
|
3692
3270
|
note: z.ZodNullable<z.ZodString>;
|
|
3693
|
-
|
|
3694
|
-
codeId: z.ZodString;
|
|
3695
|
-
hint: z.ZodString;
|
|
3696
|
-
status: z.ZodString;
|
|
3697
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
3698
|
-
}, z.core.$strip>>>>;
|
|
3699
|
-
download: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3700
|
-
count: z.ZodNumber;
|
|
3701
|
-
limit: z.ZodNumber;
|
|
3702
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
3703
|
-
firstDownloadedAt: z.ZodNullable<z.ZodString>;
|
|
3704
|
-
files: z.ZodArray<z.ZodObject<{
|
|
3705
|
-
assetId: z.ZodString;
|
|
3706
|
-
fileName: z.ZodString;
|
|
3707
|
-
sizeBytes: z.ZodNullable<z.ZodNumber>;
|
|
3708
|
-
}, z.core.$strip>>;
|
|
3709
|
-
}, z.core.$strip>>>>;
|
|
3710
|
-
mail: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3711
|
-
status: z.ZodString;
|
|
3712
|
-
sentAt: z.ZodNullable<z.ZodString>;
|
|
3713
|
-
errorCode: z.ZodNullable<z.ZodString>;
|
|
3714
|
-
}, z.core.$strip>>>>;
|
|
3271
|
+
mode: z.ZodOptional<z.ZodString>;
|
|
3715
3272
|
}, z.core.$strip>>>>;
|
|
3716
3273
|
autoDecisionDate: z.ZodNullable<z.ZodString>;
|
|
3717
3274
|
sellerMemo: z.ZodNullable<z.ZodString>;
|
|
@@ -3807,7 +3364,6 @@ export declare const orderSchema: z.ZodObject<{
|
|
|
3807
3364
|
updatedAt: z.ZodString;
|
|
3808
3365
|
}, z.core.$strip>>>>;
|
|
3809
3366
|
}, z.core.$strip>;
|
|
3810
|
-
withdrawalAgreedAt: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
3811
3367
|
testPayment: z.ZodBoolean;
|
|
3812
3368
|
items: z.ZodArray<z.ZodObject<{
|
|
3813
3369
|
orderItemId: z.ZodString;
|
|
@@ -3839,29 +3395,7 @@ export declare const orderSchema: z.ZodObject<{
|
|
|
3839
3395
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3840
3396
|
}, z.core.$strip>;
|
|
3841
3397
|
}, z.core.$strip>, z.ZodObject<{
|
|
3842
|
-
type: z.ZodLiteral<"
|
|
3843
|
-
download: z.ZodObject<{
|
|
3844
|
-
limit: z.ZodNumber;
|
|
3845
|
-
days: z.ZodNumber;
|
|
3846
|
-
stockTracked: z.ZodBoolean;
|
|
3847
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3848
|
-
}, z.core.$strip>;
|
|
3849
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3850
|
-
type: z.ZodLiteral<"CODE">;
|
|
3851
|
-
code: z.ZodObject<{
|
|
3852
|
-
mode: z.ZodString;
|
|
3853
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3854
|
-
}, z.core.$strip>;
|
|
3855
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3856
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
3857
|
-
service: z.ZodObject<{
|
|
3858
|
-
mode: z.ZodString;
|
|
3859
|
-
}, z.core.$strip>;
|
|
3860
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
3861
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
3862
|
-
pickup: z.ZodObject<{
|
|
3863
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
3864
|
-
}, z.core.$strip>;
|
|
3398
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
3865
3399
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
3866
3400
|
type: z.ZodString;
|
|
3867
3401
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -3881,31 +3415,9 @@ export declare const orderSchema: z.ZodObject<{
|
|
|
3881
3415
|
}, z.core.$strip>>;
|
|
3882
3416
|
fulfillment: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3883
3417
|
status: z.ZodString;
|
|
3884
|
-
mode: z.ZodNullable<z.ZodString>;
|
|
3885
3418
|
fulfilledAt: z.ZodString;
|
|
3886
3419
|
note: z.ZodNullable<z.ZodString>;
|
|
3887
|
-
|
|
3888
|
-
codeId: z.ZodString;
|
|
3889
|
-
hint: z.ZodString;
|
|
3890
|
-
status: z.ZodString;
|
|
3891
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
3892
|
-
}, z.core.$strip>>>>;
|
|
3893
|
-
download: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3894
|
-
count: z.ZodNumber;
|
|
3895
|
-
limit: z.ZodNumber;
|
|
3896
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
3897
|
-
firstDownloadedAt: z.ZodNullable<z.ZodString>;
|
|
3898
|
-
files: z.ZodArray<z.ZodObject<{
|
|
3899
|
-
assetId: z.ZodString;
|
|
3900
|
-
fileName: z.ZodString;
|
|
3901
|
-
sizeBytes: z.ZodNullable<z.ZodNumber>;
|
|
3902
|
-
}, z.core.$strip>>;
|
|
3903
|
-
}, z.core.$strip>>>>;
|
|
3904
|
-
mail: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
3905
|
-
status: z.ZodString;
|
|
3906
|
-
sentAt: z.ZodNullable<z.ZodString>;
|
|
3907
|
-
errorCode: z.ZodNullable<z.ZodString>;
|
|
3908
|
-
}, z.core.$strip>>>>;
|
|
3420
|
+
mode: z.ZodOptional<z.ZodString>;
|
|
3909
3421
|
}, z.core.$strip>>>>;
|
|
3910
3422
|
autoDecisionDate: z.ZodNullable<z.ZodString>;
|
|
3911
3423
|
sellerMemo: z.ZodNullable<z.ZodString>;
|
|
@@ -3989,29 +3501,7 @@ export declare const orderItemPageSchema: z.ZodObject<{
|
|
|
3989
3501
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
3990
3502
|
}, z.core.$strip>;
|
|
3991
3503
|
}, z.core.$strip>, z.ZodObject<{
|
|
3992
|
-
type: z.ZodLiteral<"
|
|
3993
|
-
download: z.ZodObject<{
|
|
3994
|
-
limit: z.ZodNumber;
|
|
3995
|
-
days: z.ZodNumber;
|
|
3996
|
-
stockTracked: z.ZodBoolean;
|
|
3997
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
3998
|
-
}, z.core.$strip>;
|
|
3999
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
4000
|
-
type: z.ZodLiteral<"CODE">;
|
|
4001
|
-
code: z.ZodObject<{
|
|
4002
|
-
mode: z.ZodString;
|
|
4003
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
4004
|
-
}, z.core.$strip>;
|
|
4005
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
4006
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
4007
|
-
service: z.ZodObject<{
|
|
4008
|
-
mode: z.ZodString;
|
|
4009
|
-
}, z.core.$strip>;
|
|
4010
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
4011
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
4012
|
-
pickup: z.ZodObject<{
|
|
4013
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
4014
|
-
}, z.core.$strip>;
|
|
3504
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
4015
3505
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
4016
3506
|
type: z.ZodString;
|
|
4017
3507
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -4031,31 +3521,9 @@ export declare const orderItemPageSchema: z.ZodObject<{
|
|
|
4031
3521
|
}, z.core.$strip>>;
|
|
4032
3522
|
fulfillment: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
4033
3523
|
status: z.ZodString;
|
|
4034
|
-
mode: z.ZodNullable<z.ZodString>;
|
|
4035
3524
|
fulfilledAt: z.ZodString;
|
|
4036
3525
|
note: z.ZodNullable<z.ZodString>;
|
|
4037
|
-
|
|
4038
|
-
codeId: z.ZodString;
|
|
4039
|
-
hint: z.ZodString;
|
|
4040
|
-
status: z.ZodString;
|
|
4041
|
-
revealedAt: z.ZodNullable<z.ZodString>;
|
|
4042
|
-
}, z.core.$strip>>>>;
|
|
4043
|
-
download: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
4044
|
-
count: z.ZodNumber;
|
|
4045
|
-
limit: z.ZodNumber;
|
|
4046
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
4047
|
-
firstDownloadedAt: z.ZodNullable<z.ZodString>;
|
|
4048
|
-
files: z.ZodArray<z.ZodObject<{
|
|
4049
|
-
assetId: z.ZodString;
|
|
4050
|
-
fileName: z.ZodString;
|
|
4051
|
-
sizeBytes: z.ZodNullable<z.ZodNumber>;
|
|
4052
|
-
}, z.core.$strip>>;
|
|
4053
|
-
}, z.core.$strip>>>>;
|
|
4054
|
-
mail: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
4055
|
-
status: z.ZodString;
|
|
4056
|
-
sentAt: z.ZodNullable<z.ZodString>;
|
|
4057
|
-
errorCode: z.ZodNullable<z.ZodString>;
|
|
4058
|
-
}, z.core.$strip>>>>;
|
|
3526
|
+
mode: z.ZodOptional<z.ZodString>;
|
|
4059
3527
|
}, z.core.$strip>>>>;
|
|
4060
3528
|
autoDecisionDate: z.ZodNullable<z.ZodString>;
|
|
4061
3529
|
sellerMemo: z.ZodNullable<z.ZodString>;
|
|
@@ -4262,12 +3730,11 @@ export declare const cancelBySellerRequestSchema: z.ZodObject<{
|
|
|
4262
3730
|
}, z.core.$strip>;
|
|
4263
3731
|
export type CancelBySellerRequest = z.infer<typeof cancelBySellerRequestSchema>;
|
|
4264
3732
|
/**
|
|
4265
|
-
* 제공 처리 요청 (이슈 #48) — `POST /v1/order-items/{orderItemId}/fulfill`.
|
|
3733
|
+
* 제공 처리 요청 (이슈 #48) — `POST /v1/order-items/{orderItemId}/fulfill`. 배송 없는 주문상품(`MANUAL`)을
|
|
4266
3734
|
* 제공 완료(`DELIVERED`)로 바꾼다.
|
|
4267
3735
|
*/
|
|
4268
3736
|
export declare const fulfillRequestSchema: z.ZodObject<{
|
|
4269
3737
|
note: z.ZodOptional<z.ZodString>;
|
|
4270
|
-
codes: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
4271
3738
|
}, z.core.$strip>;
|
|
4272
3739
|
export type FulfillRequest = z.infer<typeof fulfillRequestSchema>;
|
|
4273
3740
|
/** 제공 처리 일괄 요청 — `POST /v1/order-items/fulfill` */
|
|
@@ -5322,20 +4789,20 @@ export interface PaymentListParams extends PageParams {
|
|
|
5322
4789
|
//#endregion
|
|
5323
4790
|
//#region src/schemas/product.d.ts
|
|
5324
4791
|
export declare const productStatusSchema: z.ZodEnum<{
|
|
5325
|
-
SUSPENDED: "SUSPENDED";
|
|
5326
|
-
CLOSED: "CLOSED";
|
|
5327
4792
|
SALE: "SALE";
|
|
4793
|
+
SUSPENDED: "SUSPENDED";
|
|
5328
4794
|
OUT_OF_STOCK: "OUT_OF_STOCK";
|
|
4795
|
+
CLOSED: "CLOSED";
|
|
5329
4796
|
}>;
|
|
5330
4797
|
export type ProductStatus = z.infer<typeof productStatusSchema>;
|
|
5331
4798
|
export declare const productSummarySchema: z.ZodObject<{
|
|
5332
4799
|
productId: z.ZodString;
|
|
5333
4800
|
name: z.ZodString;
|
|
5334
4801
|
status: z.ZodEnum<{
|
|
5335
|
-
SUSPENDED: "SUSPENDED";
|
|
5336
|
-
CLOSED: "CLOSED";
|
|
5337
4802
|
SALE: "SALE";
|
|
4803
|
+
SUSPENDED: "SUSPENDED";
|
|
5338
4804
|
OUT_OF_STOCK: "OUT_OF_STOCK";
|
|
4805
|
+
CLOSED: "CLOSED";
|
|
5339
4806
|
}>;
|
|
5340
4807
|
salePrice: z.ZodNumber;
|
|
5341
4808
|
discountedPrice: z.ZodNullable<z.ZodNumber>;
|
|
@@ -5402,10 +4869,10 @@ export declare const productSchema: z.ZodObject<{
|
|
|
5402
4869
|
productId: z.ZodString;
|
|
5403
4870
|
name: z.ZodString;
|
|
5404
4871
|
status: z.ZodEnum<{
|
|
5405
|
-
SUSPENDED: "SUSPENDED";
|
|
5406
|
-
CLOSED: "CLOSED";
|
|
5407
4872
|
SALE: "SALE";
|
|
4873
|
+
SUSPENDED: "SUSPENDED";
|
|
5408
4874
|
OUT_OF_STOCK: "OUT_OF_STOCK";
|
|
4875
|
+
CLOSED: "CLOSED";
|
|
5409
4876
|
}>;
|
|
5410
4877
|
salePrice: z.ZodNumber;
|
|
5411
4878
|
discountedPrice: z.ZodNullable<z.ZodNumber>;
|
|
@@ -5459,35 +4926,7 @@ export declare const productSchema: z.ZodObject<{
|
|
|
5459
4926
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
5460
4927
|
}, z.core.$strip>;
|
|
5461
4928
|
}, z.core.$strip>, z.ZodObject<{
|
|
5462
|
-
type: z.ZodLiteral<"
|
|
5463
|
-
download: z.ZodObject<{
|
|
5464
|
-
limit: z.ZodNumber;
|
|
5465
|
-
days: z.ZodNumber;
|
|
5466
|
-
stockTracking: z.ZodBoolean;
|
|
5467
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
5468
|
-
}, z.core.$strip>;
|
|
5469
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
5470
|
-
type: z.ZodLiteral<"CODE">;
|
|
5471
|
-
code: z.ZodObject<{
|
|
5472
|
-
mode: z.ZodEnum<{
|
|
5473
|
-
AUTO: "AUTO";
|
|
5474
|
-
MANUAL: "MANUAL";
|
|
5475
|
-
}>;
|
|
5476
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
5477
|
-
}, z.core.$strip>;
|
|
5478
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
5479
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
5480
|
-
service: z.ZodObject<{
|
|
5481
|
-
mode: z.ZodEnum<{
|
|
5482
|
-
AUTO: "AUTO";
|
|
5483
|
-
MANUAL: "MANUAL";
|
|
5484
|
-
}>;
|
|
5485
|
-
}, z.core.$strip>;
|
|
5486
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
5487
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
5488
|
-
pickup: z.ZodObject<{
|
|
5489
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
5490
|
-
}, z.core.$strip>;
|
|
4929
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
5491
4930
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
5492
4931
|
type: z.ZodString;
|
|
5493
4932
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -5662,35 +5101,7 @@ export declare const productCreateRequestSchema: z.ZodObject<{
|
|
|
5662
5101
|
returnAddressId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5663
5102
|
}, z.core.$strict>>;
|
|
5664
5103
|
}, z.core.$strict>, z.ZodObject<{
|
|
5665
|
-
type: z.ZodLiteral<"
|
|
5666
|
-
download: z.ZodDefault<z.ZodObject<{
|
|
5667
|
-
limit: z.ZodDefault<z.ZodNumber>;
|
|
5668
|
-
days: z.ZodDefault<z.ZodNumber>;
|
|
5669
|
-
stockTracking: z.ZodDefault<z.ZodBoolean>;
|
|
5670
|
-
withdrawalRestricted: z.ZodDefault<z.ZodBoolean>;
|
|
5671
|
-
}, z.core.$strict>>;
|
|
5672
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5673
|
-
type: z.ZodLiteral<"CODE">;
|
|
5674
|
-
code: z.ZodDefault<z.ZodObject<{
|
|
5675
|
-
mode: z.ZodDefault<z.ZodEnum<{
|
|
5676
|
-
AUTO: "AUTO";
|
|
5677
|
-
MANUAL: "MANUAL";
|
|
5678
|
-
}>>;
|
|
5679
|
-
withdrawalRestricted: z.ZodDefault<z.ZodBoolean>;
|
|
5680
|
-
}, z.core.$strict>>;
|
|
5681
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5682
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
5683
|
-
service: z.ZodDefault<z.ZodObject<{
|
|
5684
|
-
mode: z.ZodDefault<z.ZodEnum<{
|
|
5685
|
-
AUTO: "AUTO";
|
|
5686
|
-
MANUAL: "MANUAL";
|
|
5687
|
-
}>>;
|
|
5688
|
-
}, z.core.$strict>>;
|
|
5689
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5690
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
5691
|
-
pickup: z.ZodDefault<z.ZodObject<{
|
|
5692
|
-
addressId: z.ZodOptional<z.ZodString>;
|
|
5693
|
-
}, z.core.$strict>>;
|
|
5104
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
5694
5105
|
}, z.core.$strict>], "type">>;
|
|
5695
5106
|
optionGroups: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
5696
5107
|
groupId: z.ZodOptional<z.ZodString>;
|
|
@@ -5749,35 +5160,7 @@ export declare const productReplaceRequestSchema: z.ZodObject<{
|
|
|
5749
5160
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
5750
5161
|
}, z.core.$strict>;
|
|
5751
5162
|
}, z.core.$strict>, z.ZodObject<{
|
|
5752
|
-
type: z.ZodLiteral<"
|
|
5753
|
-
download: z.ZodObject<{
|
|
5754
|
-
limit: z.ZodNumber;
|
|
5755
|
-
days: z.ZodNumber;
|
|
5756
|
-
stockTracking: z.ZodBoolean;
|
|
5757
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
5758
|
-
}, z.core.$strict>;
|
|
5759
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5760
|
-
type: z.ZodLiteral<"CODE">;
|
|
5761
|
-
code: z.ZodObject<{
|
|
5762
|
-
mode: z.ZodEnum<{
|
|
5763
|
-
AUTO: "AUTO";
|
|
5764
|
-
MANUAL: "MANUAL";
|
|
5765
|
-
}>;
|
|
5766
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
5767
|
-
}, z.core.$strict>;
|
|
5768
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5769
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
5770
|
-
service: z.ZodObject<{
|
|
5771
|
-
mode: z.ZodEnum<{
|
|
5772
|
-
AUTO: "AUTO";
|
|
5773
|
-
MANUAL: "MANUAL";
|
|
5774
|
-
}>;
|
|
5775
|
-
}, z.core.$strict>;
|
|
5776
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5777
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
5778
|
-
pickup: z.ZodObject<{
|
|
5779
|
-
addressId: z.ZodString;
|
|
5780
|
-
}, z.core.$strict>;
|
|
5163
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
5781
5164
|
}, z.core.$strict>], "type">>;
|
|
5782
5165
|
optionGroups: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
5783
5166
|
groupId: z.ZodOptional<z.ZodString>;
|
|
@@ -5824,10 +5207,10 @@ export declare const productPatchRequestSchema: z.ZodObject<{
|
|
|
5824
5207
|
name: z.ZodOptional<z.ZodString>;
|
|
5825
5208
|
salePrice: z.ZodOptional<z.ZodNumber>;
|
|
5826
5209
|
status: z.ZodOptional<z.ZodEnum<{
|
|
5827
|
-
SUSPENDED: "SUSPENDED";
|
|
5828
|
-
CLOSED: "CLOSED";
|
|
5829
5210
|
SALE: "SALE";
|
|
5211
|
+
SUSPENDED: "SUSPENDED";
|
|
5830
5212
|
OUT_OF_STOCK: "OUT_OF_STOCK";
|
|
5213
|
+
CLOSED: "CLOSED";
|
|
5831
5214
|
}>>;
|
|
5832
5215
|
fulfillment: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
5833
5216
|
type: z.ZodLiteral<"SHIPPING">;
|
|
@@ -5843,35 +5226,7 @@ export declare const productPatchRequestSchema: z.ZodObject<{
|
|
|
5843
5226
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
5844
5227
|
}, z.core.$strict>;
|
|
5845
5228
|
}, z.core.$strict>, z.ZodObject<{
|
|
5846
|
-
type: z.ZodLiteral<"
|
|
5847
|
-
download: z.ZodObject<{
|
|
5848
|
-
limit: z.ZodNumber;
|
|
5849
|
-
days: z.ZodNumber;
|
|
5850
|
-
stockTracking: z.ZodBoolean;
|
|
5851
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
5852
|
-
}, z.core.$strict>;
|
|
5853
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5854
|
-
type: z.ZodLiteral<"CODE">;
|
|
5855
|
-
code: z.ZodObject<{
|
|
5856
|
-
mode: z.ZodEnum<{
|
|
5857
|
-
AUTO: "AUTO";
|
|
5858
|
-
MANUAL: "MANUAL";
|
|
5859
|
-
}>;
|
|
5860
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
5861
|
-
}, z.core.$strict>;
|
|
5862
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5863
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
5864
|
-
service: z.ZodObject<{
|
|
5865
|
-
mode: z.ZodEnum<{
|
|
5866
|
-
AUTO: "AUTO";
|
|
5867
|
-
MANUAL: "MANUAL";
|
|
5868
|
-
}>;
|
|
5869
|
-
}, z.core.$strict>;
|
|
5870
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
5871
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
5872
|
-
pickup: z.ZodObject<{
|
|
5873
|
-
addressId: z.ZodString;
|
|
5874
|
-
}, z.core.$strict>;
|
|
5229
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
5875
5230
|
}, z.core.$strict>], "type">>;
|
|
5876
5231
|
refundPolicy: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
5877
5232
|
preShipmentDeliveryFeeRefund: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -5902,10 +5257,10 @@ export declare const productListQuerySchema: z.ZodObject<{
|
|
|
5902
5257
|
page: z.ZodOptional<z.ZodString>;
|
|
5903
5258
|
size: z.ZodOptional<z.ZodString>;
|
|
5904
5259
|
status: z.ZodOptional<z.ZodEnum<{
|
|
5905
|
-
SUSPENDED: "SUSPENDED";
|
|
5906
|
-
CLOSED: "CLOSED";
|
|
5907
5260
|
SALE: "SALE";
|
|
5261
|
+
SUSPENDED: "SUSPENDED";
|
|
5908
5262
|
OUT_OF_STOCK: "OUT_OF_STOCK";
|
|
5263
|
+
CLOSED: "CLOSED";
|
|
5909
5264
|
}>>;
|
|
5910
5265
|
categoryId: z.ZodOptional<z.ZodString>;
|
|
5911
5266
|
keyword: z.ZodOptional<z.ZodString>;
|
|
@@ -5969,8 +5324,6 @@ export declare const updateStoreRequestSchema: z.ZodObject<{
|
|
|
5969
5324
|
analyticsAllowedOrigins: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
5970
5325
|
storefrontOrigins: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
5971
5326
|
guestCheckoutEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
5972
|
-
fulfillmentMailEnabled: z.ZodOptional<z.ZodBoolean>;
|
|
5973
|
-
withdrawalNotice: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5974
5327
|
autoDeliverDays: z.ZodOptional<z.ZodNumber>;
|
|
5975
5328
|
autoConfirmDays: z.ZodOptional<z.ZodNumber>;
|
|
5976
5329
|
refundPolicy: z.ZodOptional<z.ZodObject<{
|
|
@@ -6009,8 +5362,6 @@ export declare const storeSchema: z.ZodObject<{
|
|
|
6009
5362
|
analyticsAllowedOrigins: z.ZodArray<z.ZodString>;
|
|
6010
5363
|
storefrontOrigins: z.ZodArray<z.ZodString>;
|
|
6011
5364
|
guestCheckoutEnabled: z.ZodBoolean;
|
|
6012
|
-
fulfillmentMailEnabled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
6013
|
-
withdrawalNotice: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
|
|
6014
5365
|
autoDeliverDays: z.ZodNumber;
|
|
6015
5366
|
autoConfirmDays: z.ZodNumber;
|
|
6016
5367
|
refundPolicy: z.ZodObject<{
|
|
@@ -6042,9 +5393,9 @@ export declare const storeMemberSchema: z.ZodObject<{
|
|
|
6042
5393
|
name: z.ZodString;
|
|
6043
5394
|
email: z.ZodEmail;
|
|
6044
5395
|
role: z.ZodEnum<{
|
|
6045
|
-
OWNER: "OWNER";
|
|
6046
5396
|
ADMIN: "ADMIN";
|
|
6047
5397
|
STAFF: "STAFF";
|
|
5398
|
+
OWNER: "OWNER";
|
|
6048
5399
|
}>;
|
|
6049
5400
|
joinedAt: z.ZodString;
|
|
6050
5401
|
lastActiveAt: z.ZodNullable<z.ZodString>;
|
|
@@ -6069,8 +5420,8 @@ export declare const invitationSchema: z.ZodObject<{
|
|
|
6069
5420
|
STAFF: "STAFF";
|
|
6070
5421
|
}>;
|
|
6071
5422
|
status: z.ZodEnum<{
|
|
6072
|
-
EXPIRED: "EXPIRED";
|
|
6073
5423
|
PENDING: "PENDING";
|
|
5424
|
+
EXPIRED: "EXPIRED";
|
|
6074
5425
|
ACCEPTED: "ACCEPTED";
|
|
6075
5426
|
CANCELED: "CANCELED";
|
|
6076
5427
|
}>;
|
|
@@ -6109,8 +5460,8 @@ export type UpdateMemberRoleRequest = z.infer<typeof updateMemberRoleRequestSche
|
|
|
6109
5460
|
/** `GET /v1/store/invitations` 쿼리 — OpenAPI 문서용 형태 */
|
|
6110
5461
|
export declare const invitationListQuerySchema: z.ZodObject<{
|
|
6111
5462
|
status: z.ZodOptional<z.ZodEnum<{
|
|
6112
|
-
EXPIRED: "EXPIRED";
|
|
6113
5463
|
PENDING: "PENDING";
|
|
5464
|
+
EXPIRED: "EXPIRED";
|
|
6114
5465
|
ACCEPTED: "ACCEPTED";
|
|
6115
5466
|
CANCELED: "CANCELED";
|
|
6116
5467
|
}>>;
|
|
@@ -6125,12 +5476,10 @@ export declare const storeMemberRoleUpdatedSchema: z.ZodObject<{
|
|
|
6125
5476
|
}, z.core.$strip>;
|
|
6126
5477
|
export type StoreMemberRoleUpdated = z.infer<typeof storeMemberRoleUpdatedSchema>;
|
|
6127
5478
|
/**
|
|
6128
|
-
* 주소 유형 —
|
|
6129
|
-
* (이 값을 모르는 옛 SDK의 목록 파싱이 깨지지 않게).
|
|
5479
|
+
* 주소 유형 — 출고지·반품지.
|
|
6130
5480
|
*/
|
|
6131
5481
|
export declare const addressTypeSchema: z.ZodEnum<{
|
|
6132
5482
|
SHIPPING: "SHIPPING";
|
|
6133
|
-
PICKUP: "PICKUP";
|
|
6134
5483
|
RETURN: "RETURN";
|
|
6135
5484
|
}>;
|
|
6136
5485
|
export type AddressType = z.infer<typeof addressTypeSchema>;
|
|
@@ -6138,7 +5487,6 @@ export type AddressType = z.infer<typeof addressTypeSchema>;
|
|
|
6138
5487
|
export declare const sellerAddressListQuerySchema: z.ZodObject<{
|
|
6139
5488
|
type: z.ZodOptional<z.ZodEnum<{
|
|
6140
5489
|
SHIPPING: "SHIPPING";
|
|
6141
|
-
PICKUP: "PICKUP";
|
|
6142
5490
|
RETURN: "RETURN";
|
|
6143
5491
|
}>>;
|
|
6144
5492
|
}, z.core.$strip>;
|
|
@@ -6146,7 +5494,6 @@ export declare const sellerAddressSchema: z.ZodObject<{
|
|
|
6146
5494
|
addressId: z.ZodString;
|
|
6147
5495
|
type: z.ZodEnum<{
|
|
6148
5496
|
SHIPPING: "SHIPPING";
|
|
6149
|
-
PICKUP: "PICKUP";
|
|
6150
5497
|
RETURN: "RETURN";
|
|
6151
5498
|
}>;
|
|
6152
5499
|
name: z.ZodString;
|
|
@@ -6162,7 +5509,6 @@ export type SellerAddress = z.infer<typeof sellerAddressSchema>;
|
|
|
6162
5509
|
export declare const sellerAddressRequestSchema: z.ZodObject<{
|
|
6163
5510
|
type: z.ZodEnum<{
|
|
6164
5511
|
SHIPPING: "SHIPPING";
|
|
6165
|
-
PICKUP: "PICKUP";
|
|
6166
5512
|
RETURN: "RETURN";
|
|
6167
5513
|
}>;
|
|
6168
5514
|
name: z.ZodString;
|
|
@@ -6174,19 +5520,910 @@ export declare const sellerAddressRequestSchema: z.ZodObject<{
|
|
|
6174
5520
|
}, z.core.$strip>;
|
|
6175
5521
|
export type SellerAddressRequest = z.infer<typeof sellerAddressRequestSchema>;
|
|
6176
5522
|
//#endregion
|
|
5523
|
+
//#region src/schemas/storefront-hosting.d.ts
|
|
5524
|
+
/**
|
|
5525
|
+
* 스토어프론트 호스팅 (이슈 #53, M1: 템플릿 발행) — 관리 API `/v1/storefront/**`의 계약이다.
|
|
5526
|
+
*
|
|
5527
|
+
* 셀러는 템플릿을 골라 사이트를 만들고 `{slug}.{호스팅 도메인}` 주소를 받는다. 발행은 버전 단위이고,
|
|
5528
|
+
* 되돌리기는 이전 버전을 다시 발행하는 것이다(재빌드 없음). 상태의 원천은 api DB이고 Cloudflare 쪽 반영
|
|
5529
|
+
* (라우팅 표·사이트 Worker)은 커밋 뒤 비동기다 — 반영 상태는 `provisioning`으로 본다.
|
|
5530
|
+
*
|
|
5531
|
+
* 스코프는 조회 `storefront:r`, 쓰기 `storefront:rw`(역할 OWNER·ADMIN)다. 에이전트(MCP)의 발행·되돌리기·템플릿 변경·
|
|
5532
|
+
* 공개 전환·슬러그 변경·호스팅 끄기는 승인(`APPROVAL_REQUIRED`)이다 — 구매자가 보는 화면을 바꾸는 쓰기다.
|
|
5533
|
+
*
|
|
5534
|
+
* 오류 코드:
|
|
5535
|
+
* - 403 `STOREFRONT_HOSTING_DISABLED` — 플랫폼 스위치가 꺼져 새 사이트를 만들 수 없다
|
|
5536
|
+
* - 404 `STOREFRONT_SITE_NOT_FOUND` · `STOREFRONT_TEMPLATE_NOT_FOUND` · `STOREFRONT_VERSION_NOT_FOUND`
|
|
5537
|
+
* - 409 `STOREFRONT_SITE_EXISTS` — 이미 사이트가 있다(스토어당 1개)
|
|
5538
|
+
* - 409 `STOREFRONT_SLUG_TAKEN` — 다른 사이트가 쓰거나 보류 중인 슬러그다
|
|
5539
|
+
* - 409 `STOREFRONT_SLUG_CHANGE_LIMIT` — 슬러그는 스토어당 30일에 3번까지 바꾼다
|
|
5540
|
+
* - 409 `STOREFRONT_SITE_CREATE_LIMIT` — 사이트는 스토어당 30일에 3번까지 만든다
|
|
5541
|
+
* - 409 `STOREFRONT_SITE_CHANGED` — 읽은 상태(`expected*`)와 현재 상태가 다르다. 다시 읽고 시도한다
|
|
5542
|
+
* - 409 `STOREFRONT_SITE_NOT_ACTIVE` — 정지(`SUSPENDED`)된 사이트는 바꾸거나 끌 수 없다
|
|
5543
|
+
* - 409 `STOREFRONT_VERSION_NOT_READY` — 빌드가 끝나지 않았거나 실패한 버전은 발행할 수 없다
|
|
5544
|
+
* - 409 `STOREFRONT_NO_ROLLBACK_TARGET` — 되돌릴 이전 발행 버전이 없다
|
|
5545
|
+
* - 400 `STOREFRONT_SLUG_CONFIRM_MISMATCH` — 호스팅 끄기 확인 입력이 현재 슬러그와 다르다
|
|
5546
|
+
* - 503 `STOREFRONT_PREVIEW_NOT_CONFIGURED` — 미리보기 서명 키가 설정되지 않았다
|
|
5547
|
+
*
|
|
5548
|
+
* 편집(M2b, `/v1/storefront/site/editing`·`files/**`·`checks/**`·`verify`·`builds/**`, 버전 만들기):
|
|
5549
|
+
* - 403 `STOREFRONT_EDITING_DISABLED` — 플랫폼 편집 스위치가 꺼져 있다
|
|
5550
|
+
* - 503 `STOREFRONT_EDITING_NOT_CONFIGURED` — 편집 Sandbox가 설정되지 않았다
|
|
5551
|
+
* - 409 `EDIT_CAPACITY_FULL` — 플랫폼 전체 동시 편집 상한에 걸렸다. `error.details.retryAfterSeconds` 뒤에 다시 한다
|
|
5552
|
+
* - 409 `EDIT_SESSION_REQUIRED` — 편집 미리보기 링크: 편집 환경이 없다
|
|
5553
|
+
* - 409 `CHECK_RUNNING` — 이 사이트에서 다른 종류의 검사가 돌고 있다(`error.details.checkId`)
|
|
5554
|
+
* - 404 `STOREFRONT_CHECK_NOT_FOUND`
|
|
5555
|
+
* - 409 `FILE_CHANGED` — 해시 조건이 어긋났다. 아무것도 쓰지 않았다(`error.details.conflicts: [{ path, currentHash }]`)
|
|
5556
|
+
* - 409 `FILE_EXISTS` — 옮길 자리에 파일이 있다(`overwrite: true`로 덮는다)
|
|
5557
|
+
* - 404 `FILE_NOT_FOUND` — 파일이 없다
|
|
5558
|
+
* - 400 `INVALID_FILE_PATH` — 경로 형식이 틀렸거나 편집할 수 없는 경로다(`node_modules`·`dist`·`.env*` 등). 쓸 수 있는 곳은
|
|
5559
|
+
* `src/**`·`public/**`와 루트 설정 파일 몇 개이고, `package.json`·`pnpm-lock.yaml`은 읽기만 된다
|
|
5560
|
+
* - 413 `FILE_TOO_LARGE`·`WORKSPACE_TOO_LARGE` — 파일 하나 1MiB, 작업 트리 전체 20MiB·2,000개를 넘는다
|
|
5561
|
+
* - 409 `STOREFRONT_BUILD_IN_PROGRESS` — 이 사이트에 끝나지 않은 빌드가 있다(사이트당 하나)
|
|
5562
|
+
* - 404 `STOREFRONT_BUILD_NOT_FOUND`
|
|
5563
|
+
* - 502 `STOREFRONT_SANDBOX_UNAVAILABLE` — 편집 Sandbox 호출이 실패했다. 잠시 뒤 다시 한다
|
|
5564
|
+
*/
|
|
5565
|
+
/**
|
|
5566
|
+
* 슬러그 형식 — 스토어 코드와 같은 DNS 라벨 규칙(소문자·숫자·하이픈 3~30자, 하이픈으로 시작·끝 불가)에
|
|
5567
|
+
* 연속 하이픈 금지를 더한다. `--`는 버전 미리보기 주소(`v3--{slug}`)와 punycode(`xn--`)가 쓰는 구분자다.
|
|
5568
|
+
*/
|
|
5569
|
+
export declare const STOREFRONT_SLUG_PATTERN: RegExp;
|
|
5570
|
+
/** 호스팅 도메인에서 플랫폼이 쓰거나 쓸 이름 — 스토어 코드 예약어에 호스팅 전용 이름을 더한다 */
|
|
5571
|
+
export declare const RESERVED_STOREFRONT_SLUGS: readonly string[];
|
|
5572
|
+
/**
|
|
5573
|
+
* 편집 미리보기 호스트 접미사 — 편집 미리보기 주소는 `{사이트 id 정규화}-preview.{호스팅 도메인}`이다(M2b). 사이트 주소와 같은
|
|
5574
|
+
* 1단계 이름이라 슬러그가 이 모양이면 남의 편집 미리보기 주소와 겹칠 수 있어 슬러그로 쓰지 못한다.
|
|
5575
|
+
*/
|
|
5576
|
+
export declare const STOREFRONT_EDIT_PREVIEW_SUFFIX = "-preview";
|
|
5577
|
+
export declare function isReservedStorefrontSlug(slug: string): boolean;
|
|
5578
|
+
/**
|
|
5579
|
+
* 편집 미리보기 호스트 이름의 라벨 — 사이트 id의 `_`를 `-`로 바꾸고 `-preview`를 붙인다(`sfs_ab12cd34` → `sfs-ab12cd34-preview`).
|
|
5580
|
+
* 편집 Sandbox Worker(`apps/hosting-sandbox/src/preview-host.ts`)가 같은 규칙의 복제본을 들고 있고 api
|
|
5581
|
+
* `test/storefront-hosting-parity.spec.ts`가 둘을 대조한다. 규칙을 바꾸면 두 곳을 같이 고친다.
|
|
5582
|
+
*/
|
|
5583
|
+
export declare function storefrontEditPreviewLabelOf(siteId: string): string;
|
|
5584
|
+
export declare const storefrontSlugSchema: z.ZodString;
|
|
5585
|
+
/** 바꾼 슬러그를 다른 사이트가 가져가지 못하게 막는 기간(일). 보류 동안 옛 주소는 새 주소로 301한다 */
|
|
5586
|
+
export declare const STOREFRONT_SLUG_HOLD_DAYS = 90;
|
|
5587
|
+
/** 슬러그 변경 한도 — 이 기간(일) 안에 */
|
|
5588
|
+
export declare const STOREFRONT_SLUG_CHANGE_WINDOW_DAYS = 30;
|
|
5589
|
+
/** 슬러그 변경 한도 — 횟수(스토어 단위. 끄고 다시 만들어도 이어서 센다) */
|
|
5590
|
+
export declare const STOREFRONT_SLUG_CHANGE_LIMIT = 3;
|
|
5591
|
+
/** 사이트 만들기 한도 — 같은 창(30일) 안의 횟수(스토어 단위). 끄고 만들기를 되풀이해 이름을 묶어 두지 못하게 한다 */
|
|
5592
|
+
export declare const STOREFRONT_SITE_CREATE_LIMIT = 3;
|
|
5593
|
+
export declare const storefrontTemplateSchema: z.ZodObject<{
|
|
5594
|
+
templateId: z.ZodString;
|
|
5595
|
+
name: z.ZodString;
|
|
5596
|
+
industry: z.ZodString;
|
|
5597
|
+
description: z.ZodString;
|
|
5598
|
+
thumbnailUrl: z.ZodNullable<z.ZodString>;
|
|
5599
|
+
version: z.ZodString;
|
|
5600
|
+
isDefault: z.ZodBoolean;
|
|
5601
|
+
}, z.core.$strip>;
|
|
5602
|
+
export type StorefrontTemplate = z.infer<typeof storefrontTemplateSchema>;
|
|
5603
|
+
/**
|
|
5604
|
+
* 버전 상태 — 템플릿 버전(`source: TEMPLATE`)은 템플릿 산출물을 그대로 쓰므로 만들 때 곧바로 `READY`다. 편집 버전
|
|
5605
|
+
* (`source: EDIT`, M2b)은 작업 트리 스냅샷을 빌드하는 동안 `BUILDING`이고, 빌드·규칙 검증을 통과하면 `READY`, 실패하면
|
|
5606
|
+
* `FAILED`다(실패 단계·로그 꼬리는 `buildId`의 빌드). 발행할 수 있는 것은 `READY`뿐이다. 발행 여부는 상태가 아니라 사이트의
|
|
5607
|
+
* 발행 포인터가 원천이다(`published`).
|
|
5608
|
+
*/
|
|
5609
|
+
export declare const storefrontVersionStatusSchema: z.ZodEnum<{
|
|
5610
|
+
FAILED: "FAILED";
|
|
5611
|
+
BUILDING: "BUILDING";
|
|
5612
|
+
READY: "READY";
|
|
5613
|
+
}>;
|
|
5614
|
+
export type StorefrontVersionStatus = z.infer<typeof storefrontVersionStatusSchema>;
|
|
5615
|
+
export declare const storefrontVersionSchema: z.ZodObject<{
|
|
5616
|
+
versionId: z.ZodString;
|
|
5617
|
+
number: z.ZodNumber;
|
|
5618
|
+
templateId: z.ZodString;
|
|
5619
|
+
templateVersion: z.ZodString;
|
|
5620
|
+
status: z.ZodEnum<{
|
|
5621
|
+
FAILED: "FAILED";
|
|
5622
|
+
BUILDING: "BUILDING";
|
|
5623
|
+
READY: "READY";
|
|
5624
|
+
}>;
|
|
5625
|
+
published: z.ZodBoolean;
|
|
5626
|
+
publishedAt: z.ZodNullable<z.ZodString>;
|
|
5627
|
+
message: z.ZodNullable<z.ZodString>;
|
|
5628
|
+
source: z.ZodEnum<{
|
|
5629
|
+
TEMPLATE: "TEMPLATE";
|
|
5630
|
+
EDIT: "EDIT";
|
|
5631
|
+
}>;
|
|
5632
|
+
buildId: z.ZodNullable<z.ZodString>;
|
|
5633
|
+
createdByType: z.ZodString;
|
|
5634
|
+
createdAt: z.ZodString;
|
|
5635
|
+
}, z.core.$strip>;
|
|
5636
|
+
export type StorefrontVersion = z.infer<typeof storefrontVersionSchema>;
|
|
5637
|
+
export declare const storefrontSiteStatusSchema: z.ZodEnum<{
|
|
5638
|
+
ACTIVE: "ACTIVE";
|
|
5639
|
+
SUSPENDED: "SUSPENDED";
|
|
5640
|
+
CLOSED: "CLOSED";
|
|
5641
|
+
}>;
|
|
5642
|
+
export type StorefrontSiteStatus = z.infer<typeof storefrontSiteStatusSchema>;
|
|
5643
|
+
export declare const storefrontVisibilitySchema: z.ZodEnum<{
|
|
5644
|
+
COMING_SOON: "COMING_SOON";
|
|
5645
|
+
PUBLIC: "PUBLIC";
|
|
5646
|
+
}>;
|
|
5647
|
+
export type StorefrontVisibility = z.infer<typeof storefrontVisibilitySchema>;
|
|
5648
|
+
export declare const storefrontSourceModeSchema: z.ZodEnum<{
|
|
5649
|
+
CUSTOM: "CUSTOM";
|
|
5650
|
+
MANAGED: "MANAGED";
|
|
5651
|
+
}>;
|
|
5652
|
+
export declare const storefrontDomainSchema: z.ZodObject<{
|
|
5653
|
+
hostname: z.ZodString;
|
|
5654
|
+
kind: z.ZodEnum<{
|
|
5655
|
+
PLATFORM: "PLATFORM";
|
|
5656
|
+
CUSTOM: "CUSTOM";
|
|
5657
|
+
}>;
|
|
5658
|
+
status: z.ZodEnum<{
|
|
5659
|
+
ACTIVE: "ACTIVE";
|
|
5660
|
+
HELD: "HELD";
|
|
5661
|
+
}>;
|
|
5662
|
+
isPrimary: z.ZodBoolean;
|
|
5663
|
+
holdUntil: z.ZodNullable<z.ZodString>;
|
|
5664
|
+
}, z.core.$strip>;
|
|
5665
|
+
export type StorefrontDomain = z.infer<typeof storefrontDomainSchema>;
|
|
5666
|
+
/**
|
|
5667
|
+
* 호스팅 반영 상태 — 발행·슬러그·공개 전환은 DB에 먼저 확정되고 Cloudflare 반영은 커밋 뒤에 한다.
|
|
5668
|
+
* `PENDING`이면 반영 중이거나 재시도 대기다(잡이 다시 한다). 반영 뒤에도 라우팅 전파에 최대 1분이 걸린다.
|
|
5669
|
+
*/
|
|
5670
|
+
export declare const storefrontProvisioningSchema: z.ZodObject<{
|
|
5671
|
+
status: z.ZodEnum<{
|
|
5672
|
+
PENDING: "PENDING";
|
|
5673
|
+
FAILED: "FAILED";
|
|
5674
|
+
SYNCED: "SYNCED";
|
|
5675
|
+
}>;
|
|
5676
|
+
lastErrorCode: z.ZodNullable<z.ZodString>;
|
|
5677
|
+
syncedAt: z.ZodNullable<z.ZodString>;
|
|
5678
|
+
}, z.core.$strip>;
|
|
5679
|
+
export type StorefrontProvisioning = z.infer<typeof storefrontProvisioningSchema>;
|
|
5680
|
+
/**
|
|
5681
|
+
* 편집 미리보기 주소(M2b) — 사이트마다 `{사이트 id 정규화}-preview.{호스팅 도메인}` 호스트 하나다. 호스팅 도메인의 와일드카드
|
|
5682
|
+
* 인증서가 덮으므로 따로 준비할 것이 없다. 이 주소는 편집 미리보기 링크(콘솔 전용)로 받은 쿠키가 있어야 열린다.
|
|
5683
|
+
*/
|
|
5684
|
+
export declare const storefrontEditPreviewSchema: z.ZodObject<{
|
|
5685
|
+
hostname: z.ZodNullable<z.ZodString>;
|
|
5686
|
+
}, z.core.$strip>;
|
|
5687
|
+
export type StorefrontEditPreview = z.infer<typeof storefrontEditPreviewSchema>;
|
|
5688
|
+
export declare const storefrontSiteSchema: z.ZodObject<{
|
|
5689
|
+
siteId: z.ZodString;
|
|
5690
|
+
slug: z.ZodString;
|
|
5691
|
+
hostname: z.ZodString;
|
|
5692
|
+
url: z.ZodString;
|
|
5693
|
+
domains: z.ZodArray<z.ZodObject<{
|
|
5694
|
+
hostname: z.ZodString;
|
|
5695
|
+
kind: z.ZodEnum<{
|
|
5696
|
+
PLATFORM: "PLATFORM";
|
|
5697
|
+
CUSTOM: "CUSTOM";
|
|
5698
|
+
}>;
|
|
5699
|
+
status: z.ZodEnum<{
|
|
5700
|
+
ACTIVE: "ACTIVE";
|
|
5701
|
+
HELD: "HELD";
|
|
5702
|
+
}>;
|
|
5703
|
+
isPrimary: z.ZodBoolean;
|
|
5704
|
+
holdUntil: z.ZodNullable<z.ZodString>;
|
|
5705
|
+
}, z.core.$strip>>;
|
|
5706
|
+
templateId: z.ZodString;
|
|
5707
|
+
sourceMode: z.ZodEnum<{
|
|
5708
|
+
CUSTOM: "CUSTOM";
|
|
5709
|
+
MANAGED: "MANAGED";
|
|
5710
|
+
}>;
|
|
5711
|
+
status: z.ZodEnum<{
|
|
5712
|
+
ACTIVE: "ACTIVE";
|
|
5713
|
+
SUSPENDED: "SUSPENDED";
|
|
5714
|
+
CLOSED: "CLOSED";
|
|
5715
|
+
}>;
|
|
5716
|
+
visibility: z.ZodEnum<{
|
|
5717
|
+
COMING_SOON: "COMING_SOON";
|
|
5718
|
+
PUBLIC: "PUBLIC";
|
|
5719
|
+
}>;
|
|
5720
|
+
publishedVersion: z.ZodNullable<z.ZodObject<{
|
|
5721
|
+
versionId: z.ZodString;
|
|
5722
|
+
number: z.ZodNumber;
|
|
5723
|
+
templateId: z.ZodString;
|
|
5724
|
+
templateVersion: z.ZodString;
|
|
5725
|
+
status: z.ZodEnum<{
|
|
5726
|
+
FAILED: "FAILED";
|
|
5727
|
+
BUILDING: "BUILDING";
|
|
5728
|
+
READY: "READY";
|
|
5729
|
+
}>;
|
|
5730
|
+
published: z.ZodBoolean;
|
|
5731
|
+
publishedAt: z.ZodNullable<z.ZodString>;
|
|
5732
|
+
message: z.ZodNullable<z.ZodString>;
|
|
5733
|
+
source: z.ZodEnum<{
|
|
5734
|
+
TEMPLATE: "TEMPLATE";
|
|
5735
|
+
EDIT: "EDIT";
|
|
5736
|
+
}>;
|
|
5737
|
+
buildId: z.ZodNullable<z.ZodString>;
|
|
5738
|
+
createdByType: z.ZodString;
|
|
5739
|
+
createdAt: z.ZodString;
|
|
5740
|
+
}, z.core.$strip>>;
|
|
5741
|
+
provisioning: z.ZodObject<{
|
|
5742
|
+
status: z.ZodEnum<{
|
|
5743
|
+
PENDING: "PENDING";
|
|
5744
|
+
FAILED: "FAILED";
|
|
5745
|
+
SYNCED: "SYNCED";
|
|
5746
|
+
}>;
|
|
5747
|
+
lastErrorCode: z.ZodNullable<z.ZodString>;
|
|
5748
|
+
syncedAt: z.ZodNullable<z.ZodString>;
|
|
5749
|
+
}, z.core.$strip>;
|
|
5750
|
+
editPreview: z.ZodObject<{
|
|
5751
|
+
hostname: z.ZodNullable<z.ZodString>;
|
|
5752
|
+
}, z.core.$strip>;
|
|
5753
|
+
slugChangesRemaining: z.ZodNumber;
|
|
5754
|
+
createdAt: z.ZodString;
|
|
5755
|
+
updatedAt: z.ZodString;
|
|
5756
|
+
}, z.core.$strip>;
|
|
5757
|
+
export type StorefrontSite = z.infer<typeof storefrontSiteSchema>;
|
|
5758
|
+
/** `GET /v1/storefront/site` — 스위치 상태와 현재 사이트(없으면 null. 끈 사이트는 싣지 않는다) */
|
|
5759
|
+
export declare const storefrontHostingSchema: z.ZodObject<{
|
|
5760
|
+
enabled: z.ZodBoolean;
|
|
5761
|
+
domain: z.ZodString;
|
|
5762
|
+
editingEnabled: z.ZodBoolean;
|
|
5763
|
+
site: z.ZodNullable<z.ZodObject<{
|
|
5764
|
+
siteId: z.ZodString;
|
|
5765
|
+
slug: z.ZodString;
|
|
5766
|
+
hostname: z.ZodString;
|
|
5767
|
+
url: z.ZodString;
|
|
5768
|
+
domains: z.ZodArray<z.ZodObject<{
|
|
5769
|
+
hostname: z.ZodString;
|
|
5770
|
+
kind: z.ZodEnum<{
|
|
5771
|
+
PLATFORM: "PLATFORM";
|
|
5772
|
+
CUSTOM: "CUSTOM";
|
|
5773
|
+
}>;
|
|
5774
|
+
status: z.ZodEnum<{
|
|
5775
|
+
ACTIVE: "ACTIVE";
|
|
5776
|
+
HELD: "HELD";
|
|
5777
|
+
}>;
|
|
5778
|
+
isPrimary: z.ZodBoolean;
|
|
5779
|
+
holdUntil: z.ZodNullable<z.ZodString>;
|
|
5780
|
+
}, z.core.$strip>>;
|
|
5781
|
+
templateId: z.ZodString;
|
|
5782
|
+
sourceMode: z.ZodEnum<{
|
|
5783
|
+
CUSTOM: "CUSTOM";
|
|
5784
|
+
MANAGED: "MANAGED";
|
|
5785
|
+
}>;
|
|
5786
|
+
status: z.ZodEnum<{
|
|
5787
|
+
ACTIVE: "ACTIVE";
|
|
5788
|
+
SUSPENDED: "SUSPENDED";
|
|
5789
|
+
CLOSED: "CLOSED";
|
|
5790
|
+
}>;
|
|
5791
|
+
visibility: z.ZodEnum<{
|
|
5792
|
+
COMING_SOON: "COMING_SOON";
|
|
5793
|
+
PUBLIC: "PUBLIC";
|
|
5794
|
+
}>;
|
|
5795
|
+
publishedVersion: z.ZodNullable<z.ZodObject<{
|
|
5796
|
+
versionId: z.ZodString;
|
|
5797
|
+
number: z.ZodNumber;
|
|
5798
|
+
templateId: z.ZodString;
|
|
5799
|
+
templateVersion: z.ZodString;
|
|
5800
|
+
status: z.ZodEnum<{
|
|
5801
|
+
FAILED: "FAILED";
|
|
5802
|
+
BUILDING: "BUILDING";
|
|
5803
|
+
READY: "READY";
|
|
5804
|
+
}>;
|
|
5805
|
+
published: z.ZodBoolean;
|
|
5806
|
+
publishedAt: z.ZodNullable<z.ZodString>;
|
|
5807
|
+
message: z.ZodNullable<z.ZodString>;
|
|
5808
|
+
source: z.ZodEnum<{
|
|
5809
|
+
TEMPLATE: "TEMPLATE";
|
|
5810
|
+
EDIT: "EDIT";
|
|
5811
|
+
}>;
|
|
5812
|
+
buildId: z.ZodNullable<z.ZodString>;
|
|
5813
|
+
createdByType: z.ZodString;
|
|
5814
|
+
createdAt: z.ZodString;
|
|
5815
|
+
}, z.core.$strip>>;
|
|
5816
|
+
provisioning: z.ZodObject<{
|
|
5817
|
+
status: z.ZodEnum<{
|
|
5818
|
+
PENDING: "PENDING";
|
|
5819
|
+
FAILED: "FAILED";
|
|
5820
|
+
SYNCED: "SYNCED";
|
|
5821
|
+
}>;
|
|
5822
|
+
lastErrorCode: z.ZodNullable<z.ZodString>;
|
|
5823
|
+
syncedAt: z.ZodNullable<z.ZodString>;
|
|
5824
|
+
}, z.core.$strip>;
|
|
5825
|
+
editPreview: z.ZodObject<{
|
|
5826
|
+
hostname: z.ZodNullable<z.ZodString>;
|
|
5827
|
+
}, z.core.$strip>;
|
|
5828
|
+
slugChangesRemaining: z.ZodNumber;
|
|
5829
|
+
createdAt: z.ZodString;
|
|
5830
|
+
updatedAt: z.ZodString;
|
|
5831
|
+
}, z.core.$strip>>;
|
|
5832
|
+
}, z.core.$strip>;
|
|
5833
|
+
export type StorefrontHosting = z.infer<typeof storefrontHostingSchema>;
|
|
5834
|
+
export declare const storefrontSlugAvailabilitySchema: z.ZodObject<{
|
|
5835
|
+
slug: z.ZodString;
|
|
5836
|
+
available: z.ZodBoolean;
|
|
5837
|
+
reason: z.ZodNullable<z.ZodEnum<{
|
|
5838
|
+
RESERVED: "RESERVED";
|
|
5839
|
+
INVALID: "INVALID";
|
|
5840
|
+
TAKEN: "TAKEN";
|
|
5841
|
+
CURRENT: "CURRENT";
|
|
5842
|
+
}>>;
|
|
5843
|
+
}, z.core.$strip>;
|
|
5844
|
+
export type StorefrontSlugAvailability = z.infer<typeof storefrontSlugAvailabilitySchema>;
|
|
5845
|
+
export declare const createStorefrontSiteRequestSchema: z.ZodObject<{
|
|
5846
|
+
templateId: z.ZodString;
|
|
5847
|
+
slug: z.ZodOptional<z.ZodString>;
|
|
5848
|
+
}, z.core.$strip>;
|
|
5849
|
+
export type CreateStorefrontSiteRequest = z.infer<typeof createStorefrontSiteRequestSchema>;
|
|
5850
|
+
export declare const changeStorefrontTemplateRequestSchema: z.ZodObject<{
|
|
5851
|
+
templateId: z.ZodString;
|
|
5852
|
+
publish: z.ZodOptional<z.ZodBoolean>;
|
|
5853
|
+
message: z.ZodOptional<z.ZodString>;
|
|
5854
|
+
}, z.core.$strip>;
|
|
5855
|
+
export type ChangeStorefrontTemplateRequest = z.infer<typeof changeStorefrontTemplateRequestSchema>;
|
|
5856
|
+
/**
|
|
5857
|
+
* 발행·되돌리기 — 발행은 사이트의 발행 포인터를 바꾸는 조건부 쓰기다. `expectedPublishedVersionId`를 주면
|
|
5858
|
+
* 지금 발행 버전이 그 값일 때만 바꾼다(화면을 본 뒤 다른 사람이 바꿨으면 409 `STOREFRONT_SITE_CHANGED`).
|
|
5859
|
+
* 이미 그 버전이 발행돼 있으면 아무것도 바꾸지 않고 200이다(같은 요청의 재실행이 안전하다).
|
|
5860
|
+
*/
|
|
5861
|
+
export declare const publishStorefrontVersionRequestSchema: z.ZodObject<{
|
|
5862
|
+
expectedPublishedVersionId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5863
|
+
}, z.core.$strip>;
|
|
5864
|
+
export type PublishStorefrontVersionRequest = z.infer<typeof publishStorefrontVersionRequestSchema>;
|
|
5865
|
+
export declare const rollbackStorefrontRequestSchema: z.ZodObject<{
|
|
5866
|
+
versionId: z.ZodOptional<z.ZodString>;
|
|
5867
|
+
expectedPublishedVersionId: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
5868
|
+
}, z.core.$strip>;
|
|
5869
|
+
export type RollbackStorefrontRequest = z.infer<typeof rollbackStorefrontRequestSchema>;
|
|
5870
|
+
export declare const changeStorefrontSlugRequestSchema: z.ZodObject<{
|
|
5871
|
+
slug: z.ZodString;
|
|
5872
|
+
}, z.core.$strip>;
|
|
5873
|
+
export type ChangeStorefrontSlugRequest = z.infer<typeof changeStorefrontSlugRequestSchema>;
|
|
5874
|
+
export declare const setStorefrontVisibilityRequestSchema: z.ZodObject<{
|
|
5875
|
+
visibility: z.ZodEnum<{
|
|
5876
|
+
COMING_SOON: "COMING_SOON";
|
|
5877
|
+
PUBLIC: "PUBLIC";
|
|
5878
|
+
}>;
|
|
5879
|
+
expectedVisibility: z.ZodOptional<z.ZodEnum<{
|
|
5880
|
+
COMING_SOON: "COMING_SOON";
|
|
5881
|
+
PUBLIC: "PUBLIC";
|
|
5882
|
+
}>>;
|
|
5883
|
+
}, z.core.$strip>;
|
|
5884
|
+
export type SetStorefrontVisibilityRequest = z.infer<typeof setStorefrontVisibilityRequestSchema>;
|
|
5885
|
+
/** 호스팅 끄기 — 사이트를 닫고(`CLOSED`) 슬러그를 보류한다. 확인 입력은 현재 슬러그다 */
|
|
5886
|
+
export declare const disableStorefrontHostingRequestSchema: z.ZodObject<{
|
|
5887
|
+
confirmSlug: z.ZodString;
|
|
5888
|
+
}, z.core.$strip>;
|
|
5889
|
+
export type DisableStorefrontHostingRequest = z.infer<typeof disableStorefrontHostingRequestSchema>;
|
|
5890
|
+
export declare const storefrontSlugAvailabilityQuerySchema: z.ZodObject<{
|
|
5891
|
+
slug: z.ZodString;
|
|
5892
|
+
}, z.core.$strip>;
|
|
5893
|
+
/**
|
|
5894
|
+
* 오픈 준비 중 미리보기 링크 — 콘솔에서 로그인한 OWNER·ADMIN만 받는다(PAT·에이전트 불가). 링크는 5분 안에 한 번 열면
|
|
5895
|
+
* 그 브라우저에 12시간짜리 미리보기 쿠키가 생기고 오픈 준비 중인 사이트의 실제 화면을 본다. 링크를 남에게 넘기면 그 사람도
|
|
5896
|
+
* 볼 수 있으므로 공유하지 않는다.
|
|
5897
|
+
*/
|
|
5898
|
+
export declare const createStorefrontPreviewLinkRequestSchema: z.ZodObject<{
|
|
5899
|
+
path: z.ZodOptional<z.ZodString>;
|
|
5900
|
+
}, z.core.$strip>;
|
|
5901
|
+
export type CreateStorefrontPreviewLinkRequest = z.infer<typeof createStorefrontPreviewLinkRequestSchema>;
|
|
5902
|
+
export declare const storefrontPreviewLinkSchema: z.ZodObject<{
|
|
5903
|
+
url: z.ZodString;
|
|
5904
|
+
expiresAt: z.ZodString;
|
|
5905
|
+
}, z.core.$strip>;
|
|
5906
|
+
export type StorefrontPreviewLink = z.infer<typeof storefrontPreviewLinkSchema>;
|
|
5907
|
+
/** 플랫폼 전체 동시 편집 환경 상한 */
|
|
5908
|
+
export declare const STOREFRONT_EDIT_CAPACITY = 20;
|
|
5909
|
+
/** 활동이 없으면 편집 환경이 잠드는 시간(분). 작업 트리는 보존된다 */
|
|
5910
|
+
export declare const STOREFRONT_EDIT_IDLE_MINUTES = 15;
|
|
5911
|
+
/**
|
|
5912
|
+
* 편집 작업(파일 쓰기·검사·버전 만들기·편집 미리보기 링크 발급)이 없으면 서버가 편집 환경을 닫는 시간(분). 미리보기 탭만 열어 두면
|
|
5913
|
+
* 유휴 잠들기(`STOREFRONT_EDIT_IDLE_MINUTES`)가 걸리지 않으므로 이 한도가 편집 환경을 끝낸다. 작업 트리는 보존된다
|
|
5914
|
+
*/
|
|
5915
|
+
export declare const STOREFRONT_EDIT_ACTIVITY_TIMEOUT_MINUTES = 30;
|
|
5916
|
+
/** 파일 하나의 최대 크기(바이트) */
|
|
5917
|
+
export declare const STOREFRONT_FILE_MAX_BYTES: number;
|
|
5918
|
+
/** 작업 트리 전체 최대 크기(바이트) — 파일 수는 2,000개까지 */
|
|
5919
|
+
export declare const STOREFRONT_WORKSPACE_MAX_BYTES: number;
|
|
5920
|
+
/** 일괄 쓰기 한 번의 최대 파일 수 */
|
|
5921
|
+
export declare const STOREFRONT_FILE_BATCH_MAX = 50;
|
|
5922
|
+
/** 편집할 수 없는 경로 조각 — 설치물·산출물 폴더 */
|
|
5923
|
+
export declare const STOREFRONT_BLOCKED_PATH_SEGMENTS: readonly string[];
|
|
5924
|
+
/** 경로 조각에 쓸 수 있는 문자 — 편집 Sandbox Worker의 경로 규칙(sandbox-api.md §2.1)과 같다. TanStack Router 파일명(`$id.tsx`·`_layout`·`(group)`·`[.]`)이 들어간다 */
|
|
5925
|
+
export declare const STOREFRONT_PATH_SEGMENT_PATTERN: RegExp;
|
|
5926
|
+
/** 경로 정규화 — NFC. 비교·저장은 이 값으로 한다(같아 보이는 두 경로가 다른 파일이 되지 않게) */
|
|
5927
|
+
export declare function normalizeStorefrontPath(path: string): string;
|
|
5928
|
+
/**
|
|
5929
|
+
* 작업 트리 상대 경로인가(정규화한 값 기준) — `/`로 구분하고 `/`로 시작하지 않는다. `.`·`..`·빈 조각, 조각 문자 규칙
|
|
5930
|
+
* (`STOREFRONT_PATH_SEGMENT_PATTERN`, 공백·역슬래시·제어·제로폭·bidi 문자 불가) 밖, 설치물·산출물 폴더
|
|
5931
|
+
* (`STOREFRONT_BLOCKED_PATH_SEGMENTS`), `.env`로 시작하는 조각(파일·폴더)은 받지 않는다. 최대 256자·깊이 16.
|
|
5932
|
+
* 어디에 쓸 수 있는지(`src/**`·`public/**`·루트 설정 파일)는 편집 Sandbox가 판정한다(400 `INVALID_FILE_PATH`).
|
|
5933
|
+
* 편집 Sandbox Worker가 같은 규칙의 복제본을 들고 있다(api `test/storefront-hosting-parity.spec.ts`가 대조한다).
|
|
5934
|
+
*/
|
|
5935
|
+
export declare function isEditableStorefrontPath(path: string): boolean;
|
|
5936
|
+
/** 경로 입력 — NFC로 정규화한 뒤 규칙을 본다 */
|
|
5937
|
+
export declare const storefrontFilePathSchema: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
5938
|
+
/** 파일 해시 — 내용 바이트의 SHA-256 hex(소문자 64자) */
|
|
5939
|
+
export declare const storefrontFileHashSchema: z.ZodString;
|
|
5940
|
+
export declare const storefrontFileEncodingSchema: z.ZodEnum<{
|
|
5941
|
+
utf8: "utf8";
|
|
5942
|
+
base64: "base64";
|
|
5943
|
+
}>;
|
|
5944
|
+
/**
|
|
5945
|
+
* 편집 환경 상태 — `STARTING`은 컨테이너를 띄우고 작업 트리를 복원해 dev 서버를 올리는 중이다(보통 30초 안, 최대
|
|
5946
|
+
* 90초). `RUNNING`이면 미리보기와 파일 쓰기가 바로 반영된다(HMR).
|
|
5947
|
+
*/
|
|
5948
|
+
export declare const storefrontEditSessionStatusSchema: z.ZodEnum<{
|
|
5949
|
+
STARTING: "STARTING";
|
|
5950
|
+
RUNNING: "RUNNING";
|
|
5951
|
+
}>;
|
|
5952
|
+
/** 편집 환경을 띄우는 단계 — 콘솔 진행 표시용이다. 값은 늘어날 수 있다 */
|
|
5953
|
+
export declare const STOREFRONT_EDIT_START_STAGES: readonly ["CONTAINER", "RESTORE", "DEV_SERVER"];
|
|
5954
|
+
export declare const storefrontEditSessionSchema: z.ZodObject<{
|
|
5955
|
+
sessionId: z.ZodString;
|
|
5956
|
+
status: z.ZodEnum<{
|
|
5957
|
+
STARTING: "STARTING";
|
|
5958
|
+
RUNNING: "RUNNING";
|
|
5959
|
+
}>;
|
|
5960
|
+
startStage: z.ZodNullable<z.ZodString>;
|
|
5961
|
+
startedAt: z.ZodString;
|
|
5962
|
+
lastEditedAt: z.ZodNullable<z.ZodString>;
|
|
5963
|
+
lastActiveAt: z.ZodString;
|
|
5964
|
+
idleExpiresAt: z.ZodString;
|
|
5965
|
+
closesAt: z.ZodString;
|
|
5966
|
+
}, z.core.$strip>;
|
|
5967
|
+
export type StorefrontEditSession = z.infer<typeof storefrontEditSessionSchema>;
|
|
5968
|
+
/** `GET·POST·DELETE /v1/storefront/site/editing` — 편집 환경 상태 */
|
|
5969
|
+
export declare const storefrontEditingSchema: z.ZodObject<{
|
|
5970
|
+
enabled: z.ZodBoolean;
|
|
5971
|
+
session: z.ZodNullable<z.ZodObject<{
|
|
5972
|
+
sessionId: z.ZodString;
|
|
5973
|
+
status: z.ZodEnum<{
|
|
5974
|
+
STARTING: "STARTING";
|
|
5975
|
+
RUNNING: "RUNNING";
|
|
5976
|
+
}>;
|
|
5977
|
+
startStage: z.ZodNullable<z.ZodString>;
|
|
5978
|
+
startedAt: z.ZodString;
|
|
5979
|
+
lastEditedAt: z.ZodNullable<z.ZodString>;
|
|
5980
|
+
lastActiveAt: z.ZodString;
|
|
5981
|
+
idleExpiresAt: z.ZodString;
|
|
5982
|
+
closesAt: z.ZodString;
|
|
5983
|
+
}, z.core.$strip>>;
|
|
5984
|
+
capacity: z.ZodObject<{
|
|
5985
|
+
limit: z.ZodNumber;
|
|
5986
|
+
inUse: z.ZodNumber;
|
|
5987
|
+
}, z.core.$strip>;
|
|
5988
|
+
preview: z.ZodObject<{
|
|
5989
|
+
hostname: z.ZodNullable<z.ZodString>;
|
|
5990
|
+
}, z.core.$strip>;
|
|
5991
|
+
workingTree: z.ZodObject<{
|
|
5992
|
+
modified: z.ZodBoolean;
|
|
5993
|
+
lastEditedAt: z.ZodNullable<z.ZodString>;
|
|
5994
|
+
}, z.core.$strip>;
|
|
5995
|
+
}, z.core.$strip>;
|
|
5996
|
+
export type StorefrontEditing = z.infer<typeof storefrontEditingSchema>;
|
|
5997
|
+
export declare const storefrontFileEntrySchema: z.ZodObject<{
|
|
5998
|
+
path: z.ZodString;
|
|
5999
|
+
size: z.ZodNumber;
|
|
6000
|
+
hash: z.ZodString;
|
|
6001
|
+
}, z.core.$strip>;
|
|
6002
|
+
export type StorefrontFileEntry = z.infer<typeof storefrontFileEntrySchema>;
|
|
6003
|
+
/** `GET /v1/storefront/site/files?prefix=` — 작업 트리 파일 목록(편집 환경이 없어도 된다. 편집 환경을 깨우지 않는다) */
|
|
6004
|
+
export declare const storefrontFileListSchema: z.ZodObject<{
|
|
6005
|
+
files: z.ZodArray<z.ZodObject<{
|
|
6006
|
+
path: z.ZodString;
|
|
6007
|
+
size: z.ZodNumber;
|
|
6008
|
+
hash: z.ZodString;
|
|
6009
|
+
}, z.core.$strip>>;
|
|
6010
|
+
totalBytes: z.ZodNumber;
|
|
6011
|
+
}, z.core.$strip>;
|
|
6012
|
+
export type StorefrontFileList = z.infer<typeof storefrontFileListSchema>;
|
|
6013
|
+
export declare const storefrontFileListQuerySchema: z.ZodObject<{
|
|
6014
|
+
prefix: z.ZodOptional<z.ZodString>;
|
|
6015
|
+
}, z.core.$strip>;
|
|
6016
|
+
export declare const storefrontFileContentQuerySchema: z.ZodObject<{
|
|
6017
|
+
path: z.ZodString;
|
|
6018
|
+
}, z.core.$strip>;
|
|
6019
|
+
/** `GET /v1/storefront/site/files/content?path=` — 편집 환경이 없어도 된다 */
|
|
6020
|
+
export declare const storefrontFileContentSchema: z.ZodObject<{
|
|
6021
|
+
path: z.ZodString;
|
|
6022
|
+
content: z.ZodString;
|
|
6023
|
+
encoding: z.ZodEnum<{
|
|
6024
|
+
utf8: "utf8";
|
|
6025
|
+
base64: "base64";
|
|
6026
|
+
}>;
|
|
6027
|
+
hash: z.ZodString;
|
|
6028
|
+
size: z.ZodNumber;
|
|
6029
|
+
}, z.core.$strip>;
|
|
6030
|
+
export type StorefrontFileContent = z.infer<typeof storefrontFileContentSchema>;
|
|
6031
|
+
/**
|
|
6032
|
+
* `POST /v1/storefront/site/files/batch` — 여러 파일을 한 번에 쓴다. 편집 환경이 없어도 된다(잠든 작업 트리에 바로 쓰고,
|
|
6033
|
+
* 편집 환경이 떠 있으면 미리보기에 곧바로 반영된다). `expectedHash`: 생략하면 조건 없이 쓴다 · `null`이면 파일이 없어야 한다(새 파일) · 값이면 지금
|
|
6034
|
+
* 해시가 같아야 한다. 조건을 **모두** 확인한 뒤 쓰고, 하나라도 어긋나면 아무것도 쓰지 않는다(409 `FILE_CHANGED`,
|
|
6035
|
+
* `error.details.conflicts`).
|
|
6036
|
+
*/
|
|
6037
|
+
export declare const writeStorefrontFilesRequestSchema: z.ZodObject<{
|
|
6038
|
+
files: z.ZodArray<z.ZodObject<{
|
|
6039
|
+
path: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
6040
|
+
content: z.ZodString;
|
|
6041
|
+
encoding: z.ZodOptional<z.ZodEnum<{
|
|
6042
|
+
utf8: "utf8";
|
|
6043
|
+
base64: "base64";
|
|
6044
|
+
}>>;
|
|
6045
|
+
expectedHash: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
6046
|
+
}, z.core.$strip>>;
|
|
6047
|
+
}, z.core.$strip>;
|
|
6048
|
+
export type WriteStorefrontFilesRequest = z.infer<typeof writeStorefrontFilesRequestSchema>;
|
|
6049
|
+
export declare const storefrontFileWriteResultSchema: z.ZodObject<{
|
|
6050
|
+
files: z.ZodArray<z.ZodObject<{
|
|
6051
|
+
path: z.ZodString;
|
|
6052
|
+
size: z.ZodNumber;
|
|
6053
|
+
hash: z.ZodString;
|
|
6054
|
+
}, z.core.$strip>>;
|
|
6055
|
+
}, z.core.$strip>;
|
|
6056
|
+
export type StorefrontFileWriteResult = z.infer<typeof storefrontFileWriteResultSchema>;
|
|
6057
|
+
/** 409 `FILE_CHANGED`의 `error.details` */
|
|
6058
|
+
export declare const storefrontFileConflictDetailsSchema: z.ZodObject<{
|
|
6059
|
+
conflicts: z.ZodArray<z.ZodObject<{
|
|
6060
|
+
path: z.ZodString;
|
|
6061
|
+
currentHash: z.ZodNullable<z.ZodString>;
|
|
6062
|
+
}, z.core.$strip>>;
|
|
6063
|
+
}, z.core.$strip>;
|
|
6064
|
+
export type StorefrontFileConflictDetails = z.infer<typeof storefrontFileConflictDetailsSchema>;
|
|
6065
|
+
/** `POST /v1/storefront/site/files/delete` — 없는 파일이면 `deleted: false`(조건을 주면 409 `FILE_CHANGED`) */
|
|
6066
|
+
export declare const deleteStorefrontFileRequestSchema: z.ZodObject<{
|
|
6067
|
+
path: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
6068
|
+
expectedHash: z.ZodOptional<z.ZodString>;
|
|
6069
|
+
}, z.core.$strip>;
|
|
6070
|
+
export type DeleteStorefrontFileRequest = z.infer<typeof deleteStorefrontFileRequestSchema>;
|
|
6071
|
+
export declare const storefrontFileDeleteResultSchema: z.ZodObject<{
|
|
6072
|
+
path: z.ZodString;
|
|
6073
|
+
deleted: z.ZodBoolean;
|
|
6074
|
+
}, z.core.$strip>;
|
|
6075
|
+
export type StorefrontFileDeleteResult = z.infer<typeof storefrontFileDeleteResultSchema>;
|
|
6076
|
+
/** `POST /v1/storefront/site/files/move` — 이름 바꾸기·옮기기 */
|
|
6077
|
+
export declare const moveStorefrontFileRequestSchema: z.ZodObject<{
|
|
6078
|
+
from: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
6079
|
+
to: z.ZodPipe<z.ZodString, z.ZodTransform<string, string>>;
|
|
6080
|
+
expectedHash: z.ZodOptional<z.ZodString>;
|
|
6081
|
+
overwrite: z.ZodOptional<z.ZodBoolean>;
|
|
6082
|
+
}, z.core.$strip>;
|
|
6083
|
+
export type MoveStorefrontFileRequest = z.infer<typeof moveStorefrontFileRequestSchema>;
|
|
6084
|
+
export declare const storefrontFileMoveResultSchema: z.ZodObject<{
|
|
6085
|
+
from: z.ZodString;
|
|
6086
|
+
to: z.ZodString;
|
|
6087
|
+
hash: z.ZodString;
|
|
6088
|
+
size: z.ZodNumber;
|
|
6089
|
+
}, z.core.$strip>;
|
|
6090
|
+
export type StorefrontFileMoveResult = z.infer<typeof storefrontFileMoveResultSchema>;
|
|
6091
|
+
/** `POST /v1/storefront/site/files/search` — 텍스트 파일 내용 검색(편집 환경이 없어도 된다) */
|
|
6092
|
+
/** 정규식 검색의 패턴 길이 상한 — 편집 Sandbox가 실행 비용을 막으려고 더 좁게 받는다(sandbox-api §4.6) */
|
|
6093
|
+
export declare const STOREFRONT_SEARCH_REGEX_MAX_LENGTH = 100;
|
|
6094
|
+
export declare const searchStorefrontFilesRequestSchema: z.ZodObject<{
|
|
6095
|
+
query: z.ZodString;
|
|
6096
|
+
regex: z.ZodOptional<z.ZodBoolean>;
|
|
6097
|
+
caseSensitive: z.ZodOptional<z.ZodBoolean>;
|
|
6098
|
+
pathPrefix: z.ZodOptional<z.ZodString>;
|
|
6099
|
+
maxResults: z.ZodOptional<z.ZodNumber>;
|
|
6100
|
+
}, z.core.$strip>;
|
|
6101
|
+
export type SearchStorefrontFilesRequest = z.infer<typeof searchStorefrontFilesRequestSchema>;
|
|
6102
|
+
export declare const storefrontFileSearchResultSchema: z.ZodObject<{
|
|
6103
|
+
matches: z.ZodArray<z.ZodObject<{
|
|
6104
|
+
path: z.ZodString;
|
|
6105
|
+
line: z.ZodNumber;
|
|
6106
|
+
column: z.ZodOptional<z.ZodNumber>;
|
|
6107
|
+
text: z.ZodString;
|
|
6108
|
+
}, z.core.$strip>>;
|
|
6109
|
+
truncated: z.ZodBoolean;
|
|
6110
|
+
}, z.core.$strip>;
|
|
6111
|
+
export type StorefrontFileSearchResult = z.infer<typeof storefrontFileSearchResultSchema>;
|
|
6112
|
+
/**
|
|
6113
|
+
* `POST /v1/storefront/site/checks` (202) — 작업 트리에 명령 하나를 돌린다(`typecheck` 타입 검사 · `lint` · `test`). 편집 환경이
|
|
6114
|
+
* 없어도 된다(일회용 검사 컨테이너에서 돈다). 검사는 30초를 넘길 수 있어 **항상 202로 검사 id만 주고** 결과는
|
|
6115
|
+
* `GET /v1/storefront/site/checks/{checkId}`로 조회한다(권장 2~3초 간격). 사이트당 끝나지 않은 검사는 하나다 — 같은 종류가 돌고
|
|
6116
|
+
* 있으면 그 검사를 다시 돌려주고, 다른 종류면 409 `CHECK_RUNNING`(`error.details.checkId`)이다. 출력은 꼬리만 준다.
|
|
6117
|
+
*/
|
|
6118
|
+
export declare const runStorefrontCheckRequestSchema: z.ZodObject<{
|
|
6119
|
+
check: z.ZodEnum<{
|
|
6120
|
+
typecheck: "typecheck";
|
|
6121
|
+
lint: "lint";
|
|
6122
|
+
test: "test";
|
|
6123
|
+
}>;
|
|
6124
|
+
}, z.core.$strip>;
|
|
6125
|
+
export type RunStorefrontCheckRequest = z.infer<typeof runStorefrontCheckRequestSchema>;
|
|
6126
|
+
export declare const storefrontCheckStatusSchema: z.ZodEnum<{
|
|
6127
|
+
FAILED: "FAILED";
|
|
6128
|
+
UNKNOWN: "UNKNOWN";
|
|
6129
|
+
RUNNING: "RUNNING";
|
|
6130
|
+
QUEUED: "QUEUED";
|
|
6131
|
+
PASSED: "PASSED";
|
|
6132
|
+
TIMED_OUT: "TIMED_OUT";
|
|
6133
|
+
}>;
|
|
6134
|
+
export type StorefrontCheckStatus = z.infer<typeof storefrontCheckStatusSchema>;
|
|
6135
|
+
/** 끝난 검사 상태 */
|
|
6136
|
+
export declare const STOREFRONT_CHECK_TERMINAL_STATUSES: readonly StorefrontCheckStatus[];
|
|
6137
|
+
export declare const storefrontCheckSchema: z.ZodObject<{
|
|
6138
|
+
checkId: z.ZodString;
|
|
6139
|
+
check: z.ZodString;
|
|
6140
|
+
status: z.ZodEnum<{
|
|
6141
|
+
FAILED: "FAILED";
|
|
6142
|
+
UNKNOWN: "UNKNOWN";
|
|
6143
|
+
RUNNING: "RUNNING";
|
|
6144
|
+
QUEUED: "QUEUED";
|
|
6145
|
+
PASSED: "PASSED";
|
|
6146
|
+
TIMED_OUT: "TIMED_OUT";
|
|
6147
|
+
}>;
|
|
6148
|
+
exitCode: z.ZodNullable<z.ZodNumber>;
|
|
6149
|
+
durationMs: z.ZodNullable<z.ZodNumber>;
|
|
6150
|
+
outputTail: z.ZodNullable<z.ZodString>;
|
|
6151
|
+
errorCode: z.ZodNullable<z.ZodString>;
|
|
6152
|
+
message: z.ZodNullable<z.ZodString>;
|
|
6153
|
+
createdAt: z.ZodString;
|
|
6154
|
+
startedAt: z.ZodNullable<z.ZodString>;
|
|
6155
|
+
finishedAt: z.ZodNullable<z.ZodString>;
|
|
6156
|
+
}, z.core.$strip>;
|
|
6157
|
+
export type StorefrontCheck = z.infer<typeof storefrontCheckSchema>;
|
|
6158
|
+
/** 규칙 심각도 — `error`는 버전 발행을 막는다(빌드 `VERIFY` 실패), `warning`은 알리기만 한다. 없으면 `error`로 본다 */
|
|
6159
|
+
export declare const storefrontRuleSeveritySchema: z.ZodEnum<{
|
|
6160
|
+
error: "error";
|
|
6161
|
+
warning: "warning";
|
|
6162
|
+
}>;
|
|
6163
|
+
export type StorefrontRuleSeverity = z.infer<typeof storefrontRuleSeveritySchema>;
|
|
6164
|
+
/** 규칙 하나의 검사 결과 — MCP 계측(`mcpRuleResultSchema`)과 같은 모양에 심각도를 더한다 */
|
|
6165
|
+
export declare const storefrontRuleResultSchema: z.ZodObject<{
|
|
6166
|
+
ruleId: z.ZodString;
|
|
6167
|
+
status: z.ZodEnum<{
|
|
6168
|
+
pass: "pass";
|
|
6169
|
+
violation: "violation";
|
|
6170
|
+
}>;
|
|
6171
|
+
count: z.ZodNumber;
|
|
6172
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6173
|
+
error: "error";
|
|
6174
|
+
warning: "warning";
|
|
6175
|
+
}>>;
|
|
6176
|
+
}, z.core.$strip>;
|
|
6177
|
+
export type StorefrontRuleResult = z.infer<typeof storefrontRuleResultSchema>;
|
|
6178
|
+
/**
|
|
6179
|
+
* 규칙 검증 보고서 — `@sayren/mcp`의 `verify_storefront`와 같은 모양이다(원천 `apps/mcp/src/verify.ts`). 위반마다
|
|
6180
|
+
* 고칠 자리(`file`·`line`)와 방법(`fix`·`example`)을 싣는다. `POST /v1/storefront/site/verify`(편집 환경이 잠들어 있어도
|
|
6181
|
+
* 된다)와 빌드의 `verify`가 이 모양이다.
|
|
6182
|
+
*/
|
|
6183
|
+
export declare const storefrontVerifyReportSchema: z.ZodObject<{
|
|
6184
|
+
ok: z.ZodBoolean;
|
|
6185
|
+
checkedFiles: z.ZodNumber;
|
|
6186
|
+
summary: z.ZodObject<{
|
|
6187
|
+
rules: z.ZodNumber;
|
|
6188
|
+
passed: z.ZodNumber;
|
|
6189
|
+
violated: z.ZodNumber;
|
|
6190
|
+
findings: z.ZodNumber;
|
|
6191
|
+
}, z.core.$strip>;
|
|
6192
|
+
results: z.ZodArray<z.ZodObject<{
|
|
6193
|
+
ruleId: z.ZodString;
|
|
6194
|
+
status: z.ZodEnum<{
|
|
6195
|
+
pass: "pass";
|
|
6196
|
+
violation: "violation";
|
|
6197
|
+
}>;
|
|
6198
|
+
count: z.ZodNumber;
|
|
6199
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6200
|
+
error: "error";
|
|
6201
|
+
warning: "warning";
|
|
6202
|
+
}>>;
|
|
6203
|
+
}, z.core.$strip>>;
|
|
6204
|
+
findings: z.ZodArray<z.ZodObject<{
|
|
6205
|
+
ruleId: z.ZodString;
|
|
6206
|
+
rule: z.ZodString;
|
|
6207
|
+
file: z.ZodString;
|
|
6208
|
+
line: z.ZodOptional<z.ZodNumber>;
|
|
6209
|
+
detail: z.ZodString;
|
|
6210
|
+
cause: z.ZodString;
|
|
6211
|
+
fix: z.ZodString;
|
|
6212
|
+
example: z.ZodString;
|
|
6213
|
+
doc: z.ZodString;
|
|
6214
|
+
docUrl: z.ZodString;
|
|
6215
|
+
templateFile: z.ZodOptional<z.ZodString>;
|
|
6216
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6217
|
+
error: "error";
|
|
6218
|
+
warning: "warning";
|
|
6219
|
+
}>>;
|
|
6220
|
+
}, z.core.$strip>>;
|
|
6221
|
+
message: z.ZodString;
|
|
6222
|
+
nextSteps: z.ZodArray<z.ZodString>;
|
|
6223
|
+
}, z.core.$strip>;
|
|
6224
|
+
export type StorefrontVerifyReport = z.infer<typeof storefrontVerifyReportSchema>;
|
|
6225
|
+
export declare const storefrontBuildStatusSchema: z.ZodEnum<{
|
|
6226
|
+
FAILED: "FAILED";
|
|
6227
|
+
SUCCEEDED: "SUCCEEDED";
|
|
6228
|
+
RUNNING: "RUNNING";
|
|
6229
|
+
QUEUED: "QUEUED";
|
|
6230
|
+
TIMED_OUT: "TIMED_OUT";
|
|
6231
|
+
}>;
|
|
6232
|
+
export type StorefrontBuildStatus = z.infer<typeof storefrontBuildStatusSchema>;
|
|
6233
|
+
/** 끝난 빌드 상태 */
|
|
6234
|
+
export declare const STOREFRONT_BUILD_TERMINAL_STATUSES: readonly StorefrontBuildStatus[];
|
|
6235
|
+
/**
|
|
6236
|
+
* 빌드 단계 — 이 순서로 돈다. 첫 실패에서 멈추지만 규칙 검증(`VERIFY`)은 실패해도 타입 검사까지 이어서 해 한 번에 알려 준다.
|
|
6237
|
+
* `UPLOAD`는 사이트 버전 Worker 업로드다(성공하면 발행할 수 있다). 값은 늘어날 수 있다.
|
|
6238
|
+
*/
|
|
6239
|
+
export declare const STOREFRONT_BUILD_STAGES: readonly ["VERIFY", "RESTORE", "INSTALL", "TYPECHECK", "BUILD", "BUNDLE", "PACK", "UPLOAD"];
|
|
6240
|
+
export declare const storefrontBuildSchema: z.ZodObject<{
|
|
6241
|
+
buildId: z.ZodString;
|
|
6242
|
+
versionId: z.ZodString;
|
|
6243
|
+
versionNumber: z.ZodNumber;
|
|
6244
|
+
status: z.ZodEnum<{
|
|
6245
|
+
FAILED: "FAILED";
|
|
6246
|
+
SUCCEEDED: "SUCCEEDED";
|
|
6247
|
+
RUNNING: "RUNNING";
|
|
6248
|
+
QUEUED: "QUEUED";
|
|
6249
|
+
TIMED_OUT: "TIMED_OUT";
|
|
6250
|
+
}>;
|
|
6251
|
+
failureStage: z.ZodNullable<z.ZodString>;
|
|
6252
|
+
errorCode: z.ZodNullable<z.ZodString>;
|
|
6253
|
+
logTail: z.ZodNullable<z.ZodString>;
|
|
6254
|
+
stages: z.ZodArray<z.ZodObject<{
|
|
6255
|
+
stage: z.ZodString;
|
|
6256
|
+
ok: z.ZodBoolean;
|
|
6257
|
+
durationMs: z.ZodNumber;
|
|
6258
|
+
}, z.core.$strip>>;
|
|
6259
|
+
verify: z.ZodNullable<z.ZodObject<{
|
|
6260
|
+
ok: z.ZodBoolean;
|
|
6261
|
+
checkedFiles: z.ZodNumber;
|
|
6262
|
+
summary: z.ZodObject<{
|
|
6263
|
+
rules: z.ZodNumber;
|
|
6264
|
+
passed: z.ZodNumber;
|
|
6265
|
+
violated: z.ZodNumber;
|
|
6266
|
+
findings: z.ZodNumber;
|
|
6267
|
+
}, z.core.$strip>;
|
|
6268
|
+
results: z.ZodArray<z.ZodObject<{
|
|
6269
|
+
ruleId: z.ZodString;
|
|
6270
|
+
status: z.ZodEnum<{
|
|
6271
|
+
pass: "pass";
|
|
6272
|
+
violation: "violation";
|
|
6273
|
+
}>;
|
|
6274
|
+
count: z.ZodNumber;
|
|
6275
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6276
|
+
error: "error";
|
|
6277
|
+
warning: "warning";
|
|
6278
|
+
}>>;
|
|
6279
|
+
}, z.core.$strip>>;
|
|
6280
|
+
findings: z.ZodArray<z.ZodObject<{
|
|
6281
|
+
ruleId: z.ZodString;
|
|
6282
|
+
rule: z.ZodString;
|
|
6283
|
+
file: z.ZodString;
|
|
6284
|
+
line: z.ZodOptional<z.ZodNumber>;
|
|
6285
|
+
detail: z.ZodString;
|
|
6286
|
+
cause: z.ZodString;
|
|
6287
|
+
fix: z.ZodString;
|
|
6288
|
+
example: z.ZodString;
|
|
6289
|
+
doc: z.ZodString;
|
|
6290
|
+
docUrl: z.ZodString;
|
|
6291
|
+
templateFile: z.ZodOptional<z.ZodString>;
|
|
6292
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6293
|
+
error: "error";
|
|
6294
|
+
warning: "warning";
|
|
6295
|
+
}>>;
|
|
6296
|
+
}, z.core.$strip>>;
|
|
6297
|
+
message: z.ZodString;
|
|
6298
|
+
nextSteps: z.ZodArray<z.ZodString>;
|
|
6299
|
+
}, z.core.$strip>>;
|
|
6300
|
+
queuedAt: z.ZodString;
|
|
6301
|
+
startedAt: z.ZodNullable<z.ZodString>;
|
|
6302
|
+
finishedAt: z.ZodNullable<z.ZodString>;
|
|
6303
|
+
durationMs: z.ZodNullable<z.ZodNumber>;
|
|
6304
|
+
}, z.core.$strip>;
|
|
6305
|
+
export type StorefrontBuild = z.infer<typeof storefrontBuildSchema>;
|
|
6306
|
+
export declare const storefrontBuildListQuerySchema: z.ZodObject<{
|
|
6307
|
+
limit: z.ZodOptional<z.ZodCoercedNumber<unknown>>;
|
|
6308
|
+
}, z.core.$strip>;
|
|
6309
|
+
/**
|
|
6310
|
+
* `POST /v1/storefront/site/versions` — 지금 작업 트리를 고정해 버전을 만든다(빌드 시작). 사이트당 끝나지 않은 빌드는
|
|
6311
|
+
* 하나다(409 `STOREFRONT_BUILD_IN_PROGRESS`). 편집 환경이 없어도 된다.
|
|
6312
|
+
*/
|
|
6313
|
+
export declare const createStorefrontVersionRequestSchema: z.ZodObject<{
|
|
6314
|
+
message: z.ZodOptional<z.ZodString>;
|
|
6315
|
+
}, z.core.$strip>;
|
|
6316
|
+
export type CreateStorefrontVersionRequest = z.infer<typeof createStorefrontVersionRequestSchema>;
|
|
6317
|
+
/** 버전 만들기 응답 (201) — 버전은 `BUILDING`, 빌드는 `QUEUED`로 시작한다. 결과는 `GET builds/{buildId}`로 본다 */
|
|
6318
|
+
export declare const storefrontVersionCreatedSchema: z.ZodObject<{
|
|
6319
|
+
version: z.ZodObject<{
|
|
6320
|
+
versionId: z.ZodString;
|
|
6321
|
+
number: z.ZodNumber;
|
|
6322
|
+
templateId: z.ZodString;
|
|
6323
|
+
templateVersion: z.ZodString;
|
|
6324
|
+
status: z.ZodEnum<{
|
|
6325
|
+
FAILED: "FAILED";
|
|
6326
|
+
BUILDING: "BUILDING";
|
|
6327
|
+
READY: "READY";
|
|
6328
|
+
}>;
|
|
6329
|
+
published: z.ZodBoolean;
|
|
6330
|
+
publishedAt: z.ZodNullable<z.ZodString>;
|
|
6331
|
+
message: z.ZodNullable<z.ZodString>;
|
|
6332
|
+
source: z.ZodEnum<{
|
|
6333
|
+
TEMPLATE: "TEMPLATE";
|
|
6334
|
+
EDIT: "EDIT";
|
|
6335
|
+
}>;
|
|
6336
|
+
buildId: z.ZodNullable<z.ZodString>;
|
|
6337
|
+
createdByType: z.ZodString;
|
|
6338
|
+
createdAt: z.ZodString;
|
|
6339
|
+
}, z.core.$strip>;
|
|
6340
|
+
build: z.ZodObject<{
|
|
6341
|
+
buildId: z.ZodString;
|
|
6342
|
+
versionId: z.ZodString;
|
|
6343
|
+
versionNumber: z.ZodNumber;
|
|
6344
|
+
status: z.ZodEnum<{
|
|
6345
|
+
FAILED: "FAILED";
|
|
6346
|
+
SUCCEEDED: "SUCCEEDED";
|
|
6347
|
+
RUNNING: "RUNNING";
|
|
6348
|
+
QUEUED: "QUEUED";
|
|
6349
|
+
TIMED_OUT: "TIMED_OUT";
|
|
6350
|
+
}>;
|
|
6351
|
+
failureStage: z.ZodNullable<z.ZodString>;
|
|
6352
|
+
errorCode: z.ZodNullable<z.ZodString>;
|
|
6353
|
+
logTail: z.ZodNullable<z.ZodString>;
|
|
6354
|
+
stages: z.ZodArray<z.ZodObject<{
|
|
6355
|
+
stage: z.ZodString;
|
|
6356
|
+
ok: z.ZodBoolean;
|
|
6357
|
+
durationMs: z.ZodNumber;
|
|
6358
|
+
}, z.core.$strip>>;
|
|
6359
|
+
verify: z.ZodNullable<z.ZodObject<{
|
|
6360
|
+
ok: z.ZodBoolean;
|
|
6361
|
+
checkedFiles: z.ZodNumber;
|
|
6362
|
+
summary: z.ZodObject<{
|
|
6363
|
+
rules: z.ZodNumber;
|
|
6364
|
+
passed: z.ZodNumber;
|
|
6365
|
+
violated: z.ZodNumber;
|
|
6366
|
+
findings: z.ZodNumber;
|
|
6367
|
+
}, z.core.$strip>;
|
|
6368
|
+
results: z.ZodArray<z.ZodObject<{
|
|
6369
|
+
ruleId: z.ZodString;
|
|
6370
|
+
status: z.ZodEnum<{
|
|
6371
|
+
pass: "pass";
|
|
6372
|
+
violation: "violation";
|
|
6373
|
+
}>;
|
|
6374
|
+
count: z.ZodNumber;
|
|
6375
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6376
|
+
error: "error";
|
|
6377
|
+
warning: "warning";
|
|
6378
|
+
}>>;
|
|
6379
|
+
}, z.core.$strip>>;
|
|
6380
|
+
findings: z.ZodArray<z.ZodObject<{
|
|
6381
|
+
ruleId: z.ZodString;
|
|
6382
|
+
rule: z.ZodString;
|
|
6383
|
+
file: z.ZodString;
|
|
6384
|
+
line: z.ZodOptional<z.ZodNumber>;
|
|
6385
|
+
detail: z.ZodString;
|
|
6386
|
+
cause: z.ZodString;
|
|
6387
|
+
fix: z.ZodString;
|
|
6388
|
+
example: z.ZodString;
|
|
6389
|
+
doc: z.ZodString;
|
|
6390
|
+
docUrl: z.ZodString;
|
|
6391
|
+
templateFile: z.ZodOptional<z.ZodString>;
|
|
6392
|
+
severity: z.ZodOptional<z.ZodEnum<{
|
|
6393
|
+
error: "error";
|
|
6394
|
+
warning: "warning";
|
|
6395
|
+
}>>;
|
|
6396
|
+
}, z.core.$strip>>;
|
|
6397
|
+
message: z.ZodString;
|
|
6398
|
+
nextSteps: z.ZodArray<z.ZodString>;
|
|
6399
|
+
}, z.core.$strip>>;
|
|
6400
|
+
queuedAt: z.ZodString;
|
|
6401
|
+
startedAt: z.ZodNullable<z.ZodString>;
|
|
6402
|
+
finishedAt: z.ZodNullable<z.ZodString>;
|
|
6403
|
+
durationMs: z.ZodNullable<z.ZodNumber>;
|
|
6404
|
+
}, z.core.$strip>;
|
|
6405
|
+
}, z.core.$strip>;
|
|
6406
|
+
export type StorefrontVersionCreated = z.infer<typeof storefrontVersionCreatedSchema>;
|
|
6407
|
+
/**
|
|
6408
|
+
* `POST /v1/storefront/site/editing/preview-link` — 편집 미리보기(dev 서버) 링크. 콘솔에서 로그인한 OWNER·ADMIN만
|
|
6409
|
+
* 받는다(PAT·에이전트 불가). 5분 안에 열면 그 브라우저에 미리보기 호스트 전용 쿠키(12시간)가 생긴다. 편집 환경이
|
|
6410
|
+
* 없으면 409 `EDIT_SESSION_REQUIRED`다(편집 환경이 `STARTING`이면 링크는 주고, 미리보기 화면이 기동 대기를 보여 준다).
|
|
6411
|
+
*/
|
|
6412
|
+
export declare const createStorefrontEditPreviewLinkRequestSchema: z.ZodObject<{
|
|
6413
|
+
path: z.ZodOptional<z.ZodString>;
|
|
6414
|
+
}, z.core.$strip>;
|
|
6415
|
+
export type CreateStorefrontEditPreviewLinkRequest = CreateStorefrontPreviewLinkRequest;
|
|
6416
|
+
//#endregion
|
|
6177
6417
|
//#region src/schemas/upload.d.ts
|
|
6178
6418
|
/**
|
|
6179
6419
|
* 업로드 용도. 허용 확장자와 크기 상한이 용도별로 다르다.
|
|
6180
6420
|
*
|
|
6181
6421
|
* - `product-image`: 상품 목록·상세의 상품 이미지. 목록 썸네일로 쓰이므로 정지 이미지만 받는다.
|
|
6182
6422
|
* - `description`: 상세설명 본문에 삽입하는 미디어. 동영상과 svg도 받는다.
|
|
6183
|
-
* - `digital-asset`: 파일 다운로드 상품의 판매 파일(이슈 #48). **비공개 객체**로 올라가고 공개 주소가 없다 — 구매자는 제공된
|
|
6184
|
-
* 주문상품에서 수명 300초의 서명 주소로만 받는다.
|
|
6185
6423
|
*/
|
|
6186
6424
|
export declare const uploadPurposeSchema: z.ZodEnum<{
|
|
6187
6425
|
"product-image": "product-image";
|
|
6188
6426
|
description: "description";
|
|
6189
|
-
"digital-asset": "digital-asset";
|
|
6190
6427
|
}>;
|
|
6191
6428
|
export type UploadPurpose = z.infer<typeof uploadPurposeSchema>;
|
|
6192
6429
|
export interface UploadPurposeLimit {
|
|
@@ -6201,8 +6438,6 @@ export interface UploadPurposeLimit {
|
|
|
6201
6438
|
* 직접 PUT되므로 이 검사는 셀러가 올리기 전에 알게 하는 장치이고, 실제 상한은 CDN이 강제한다.
|
|
6202
6439
|
*/
|
|
6203
6440
|
export declare const UPLOAD_PURPOSE_LIMITS: Record<UploadPurpose, UploadPurposeLimit>;
|
|
6204
|
-
/** 비공개 업로드(판매 파일)의 PUT 필수 헤더 — CDN이 이 값으로 공개 조회를 막는다 */
|
|
6205
|
-
export declare const PRIVATE_UPLOAD_HEADERS: Readonly<Record<string, string>>;
|
|
6206
6441
|
/** 파일명의 소문자 확장자. 확장자가 없으면 `""` */
|
|
6207
6442
|
export declare function uploadExtensionOf(filename: string): string;
|
|
6208
6443
|
export interface UploadRejection {
|
|
@@ -6228,7 +6463,6 @@ export declare const uploadRequestSchema: z.ZodObject<{
|
|
|
6228
6463
|
purpose: z.ZodDefault<z.ZodEnum<{
|
|
6229
6464
|
"product-image": "product-image";
|
|
6230
6465
|
description: "description";
|
|
6231
|
-
"digital-asset": "digital-asset";
|
|
6232
6466
|
}>>;
|
|
6233
6467
|
size: z.ZodOptional<z.ZodNumber>;
|
|
6234
6468
|
}, z.core.$strip>;
|
|
@@ -6236,8 +6470,6 @@ export type UploadRequest = z.infer<typeof uploadRequestSchema>;
|
|
|
6236
6470
|
export declare const uploadTicketSchema: z.ZodObject<{
|
|
6237
6471
|
url: z.ZodURL;
|
|
6238
6472
|
uploadUrl: z.ZodURL;
|
|
6239
|
-
key: z.ZodOptional<z.ZodString>;
|
|
6240
|
-
headers: z.ZodDefault<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>>;
|
|
6241
6473
|
}, z.core.$strip>;
|
|
6242
6474
|
export type UploadTicket = z.infer<typeof uploadTicketSchema>;
|
|
6243
6475
|
//#endregion
|
|
@@ -6382,7 +6614,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6382
6614
|
storeId: string;
|
|
6383
6615
|
storeName: string;
|
|
6384
6616
|
storeCode: string;
|
|
6385
|
-
role: "
|
|
6617
|
+
role: "ADMIN" | "STAFF" | "OWNER";
|
|
6386
6618
|
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
6387
6619
|
}[]>;
|
|
6388
6620
|
/** RFC 7009 — token을 폐기한다 (public client는 client_id만 동반) */
|
|
@@ -6519,8 +6751,6 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6519
6751
|
create: (body: UploadRequest) => Promise<{
|
|
6520
6752
|
url: string;
|
|
6521
6753
|
uploadUrl: string;
|
|
6522
|
-
headers: Record<string, string>;
|
|
6523
|
-
key?: string | undefined;
|
|
6524
6754
|
}>;
|
|
6525
6755
|
/**
|
|
6526
6756
|
* 자리 발급 + 바이트 PUT을 한 번에 — 끝나면 `url`이 공개 주소다.
|
|
@@ -6542,7 +6772,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6542
6772
|
contents: {
|
|
6543
6773
|
productId: string;
|
|
6544
6774
|
name: string;
|
|
6545
|
-
status: "
|
|
6775
|
+
status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
|
|
6546
6776
|
salePrice: number;
|
|
6547
6777
|
discountedPrice: number | null;
|
|
6548
6778
|
stockQuantity: number;
|
|
@@ -6558,7 +6788,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6558
6788
|
get: (productId: string) => Promise<{
|
|
6559
6789
|
productId: string;
|
|
6560
6790
|
name: string;
|
|
6561
|
-
status: "
|
|
6791
|
+
status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
|
|
6562
6792
|
salePrice: number;
|
|
6563
6793
|
discountedPrice: number | null;
|
|
6564
6794
|
stockQuantity: number;
|
|
@@ -6598,29 +6828,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6598
6828
|
returnAddressId: string | null;
|
|
6599
6829
|
};
|
|
6600
6830
|
} | {
|
|
6601
|
-
type: "
|
|
6602
|
-
download: {
|
|
6603
|
-
limit: number;
|
|
6604
|
-
days: number;
|
|
6605
|
-
stockTracking: boolean;
|
|
6606
|
-
withdrawalRestricted: boolean;
|
|
6607
|
-
};
|
|
6608
|
-
} | {
|
|
6609
|
-
type: "CODE";
|
|
6610
|
-
code: {
|
|
6611
|
-
mode: "AUTO" | "MANUAL";
|
|
6612
|
-
withdrawalRestricted: boolean;
|
|
6613
|
-
};
|
|
6614
|
-
} | {
|
|
6615
|
-
type: "SERVICE";
|
|
6616
|
-
service: {
|
|
6617
|
-
mode: "AUTO" | "MANUAL";
|
|
6618
|
-
};
|
|
6619
|
-
} | {
|
|
6620
|
-
type: "PICKUP";
|
|
6621
|
-
pickup: {
|
|
6622
|
-
addressId: string | null;
|
|
6623
|
-
};
|
|
6831
|
+
type: "MANUAL";
|
|
6624
6832
|
};
|
|
6625
6833
|
fulfillmentTypeLocked: boolean;
|
|
6626
6834
|
refundPolicy: {
|
|
@@ -6652,7 +6860,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6652
6860
|
create: (body: ProductCreateRequestInput, idempotencyKey?: string) => Promise<{
|
|
6653
6861
|
productId: string;
|
|
6654
6862
|
name: string;
|
|
6655
|
-
status: "
|
|
6863
|
+
status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
|
|
6656
6864
|
salePrice: number;
|
|
6657
6865
|
discountedPrice: number | null;
|
|
6658
6866
|
stockQuantity: number;
|
|
@@ -6692,29 +6900,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6692
6900
|
returnAddressId: string | null;
|
|
6693
6901
|
};
|
|
6694
6902
|
} | {
|
|
6695
|
-
type: "
|
|
6696
|
-
download: {
|
|
6697
|
-
limit: number;
|
|
6698
|
-
days: number;
|
|
6699
|
-
stockTracking: boolean;
|
|
6700
|
-
withdrawalRestricted: boolean;
|
|
6701
|
-
};
|
|
6702
|
-
} | {
|
|
6703
|
-
type: "CODE";
|
|
6704
|
-
code: {
|
|
6705
|
-
mode: "AUTO" | "MANUAL";
|
|
6706
|
-
withdrawalRestricted: boolean;
|
|
6707
|
-
};
|
|
6708
|
-
} | {
|
|
6709
|
-
type: "SERVICE";
|
|
6710
|
-
service: {
|
|
6711
|
-
mode: "AUTO" | "MANUAL";
|
|
6712
|
-
};
|
|
6713
|
-
} | {
|
|
6714
|
-
type: "PICKUP";
|
|
6715
|
-
pickup: {
|
|
6716
|
-
addressId: string | null;
|
|
6717
|
-
};
|
|
6903
|
+
type: "MANUAL";
|
|
6718
6904
|
};
|
|
6719
6905
|
fulfillmentTypeLocked: boolean;
|
|
6720
6906
|
refundPolicy: {
|
|
@@ -6746,7 +6932,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6746
6932
|
update: (productId: string, body: ProductReplaceRequestInput) => Promise<{
|
|
6747
6933
|
productId: string;
|
|
6748
6934
|
name: string;
|
|
6749
|
-
status: "
|
|
6935
|
+
status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
|
|
6750
6936
|
salePrice: number;
|
|
6751
6937
|
discountedPrice: number | null;
|
|
6752
6938
|
stockQuantity: number;
|
|
@@ -6786,29 +6972,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6786
6972
|
returnAddressId: string | null;
|
|
6787
6973
|
};
|
|
6788
6974
|
} | {
|
|
6789
|
-
type: "
|
|
6790
|
-
download: {
|
|
6791
|
-
limit: number;
|
|
6792
|
-
days: number;
|
|
6793
|
-
stockTracking: boolean;
|
|
6794
|
-
withdrawalRestricted: boolean;
|
|
6795
|
-
};
|
|
6796
|
-
} | {
|
|
6797
|
-
type: "CODE";
|
|
6798
|
-
code: {
|
|
6799
|
-
mode: "AUTO" | "MANUAL";
|
|
6800
|
-
withdrawalRestricted: boolean;
|
|
6801
|
-
};
|
|
6802
|
-
} | {
|
|
6803
|
-
type: "SERVICE";
|
|
6804
|
-
service: {
|
|
6805
|
-
mode: "AUTO" | "MANUAL";
|
|
6806
|
-
};
|
|
6807
|
-
} | {
|
|
6808
|
-
type: "PICKUP";
|
|
6809
|
-
pickup: {
|
|
6810
|
-
addressId: string | null;
|
|
6811
|
-
};
|
|
6975
|
+
type: "MANUAL";
|
|
6812
6976
|
};
|
|
6813
6977
|
fulfillmentTypeLocked: boolean;
|
|
6814
6978
|
refundPolicy: {
|
|
@@ -6926,110 +7090,6 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
6926
7090
|
endAt: string | null;
|
|
6927
7091
|
}>;
|
|
6928
7092
|
removeDiscount: (productId: string) => Promise<void>;
|
|
6929
|
-
/**
|
|
6930
|
-
* 코드 일괄 업로드 (이슈 #48) — 코드 발급·자동 제공 상품의 코드 풀에 올린다. `codes`와 `csv` 중 하나만 보낸다.
|
|
6931
|
-
* 받은 코드 수만큼 재고가 는다. 에러: 409 `NOT_CODE_PRODUCT`·`CODE_POOL_NOT_USED`·`CODE_UPLOAD_CONFLICT`, 400 `TOO_MANY_CODES`
|
|
6932
|
-
*/
|
|
6933
|
-
uploadCodes: (productId: string, body: FulfillmentCodeUploadRequest, idempotencyKey?: string) => Promise<{
|
|
6934
|
-
batchId: string;
|
|
6935
|
-
productId: string;
|
|
6936
|
-
variantId: string;
|
|
6937
|
-
total: number;
|
|
6938
|
-
accepted: number;
|
|
6939
|
-
duplicates: number;
|
|
6940
|
-
rejected: {
|
|
6941
|
-
line: number;
|
|
6942
|
-
reason: string;
|
|
6943
|
-
}[];
|
|
6944
|
-
expiresAt: string | null;
|
|
6945
|
-
createdAt: string;
|
|
6946
|
-
}>;
|
|
6947
|
-
/** 코드 목록 — 가린 값(`hint`)만 싣는다. `available`은 필터와 무관한 판매 가능 코드 수다 */
|
|
6948
|
-
listCodes: (productId: string, params?: PageParams & Omit<z.input<typeof fulfillmentCodeListQuerySchema>, "page" | "size">) => Promise<{
|
|
6949
|
-
page: number;
|
|
6950
|
-
size: number;
|
|
6951
|
-
totalElements: number;
|
|
6952
|
-
totalPages: number;
|
|
6953
|
-
contents: {
|
|
6954
|
-
codeId: string;
|
|
6955
|
-
productId: string;
|
|
6956
|
-
variantId: string;
|
|
6957
|
-
batchId: string | null;
|
|
6958
|
-
hint: string;
|
|
6959
|
-
status: string;
|
|
6960
|
-
orderItemId: string | null;
|
|
6961
|
-
assignedAt: string | null;
|
|
6962
|
-
revealedAt: string | null;
|
|
6963
|
-
expiresAt: string | null;
|
|
6964
|
-
createdAt: string;
|
|
6965
|
-
}[];
|
|
6966
|
-
available: number;
|
|
6967
|
-
}>;
|
|
6968
|
-
/** 판매 가능 코드 폐기 — 재고가 1 준다. 배정된 코드는 409 `CODE_NOT_AVAILABLE` */
|
|
6969
|
-
voidCode: (productId: string, codeId: string) => Promise<{
|
|
6970
|
-
codeId: string;
|
|
6971
|
-
productId: string;
|
|
6972
|
-
variantId: string;
|
|
6973
|
-
batchId: string | null;
|
|
6974
|
-
hint: string;
|
|
6975
|
-
status: string;
|
|
6976
|
-
orderItemId: string | null;
|
|
6977
|
-
assignedAt: string | null;
|
|
6978
|
-
revealedAt: string | null;
|
|
6979
|
-
expiresAt: string | null;
|
|
6980
|
-
createdAt: string;
|
|
6981
|
-
}>;
|
|
6982
|
-
/**
|
|
6983
|
-
* 판매 파일 연결 (이슈 #48) — `uploads.create({ purpose: "digital-asset" })`로 받은 `key`에 파일을 올린 뒤 연결한다.
|
|
6984
|
-
* 이후 주문부터 이 파일을 준다. 에러: 400 `INVALID_ASSET_KEY`, 409 `NOT_DOWNLOAD_PRODUCT`·`ASSET_ALREADY_ATTACHED`
|
|
6985
|
-
*/
|
|
6986
|
-
attachDigitalAsset: (productId: string, body: DigitalAssetAttachRequest) => Promise<{
|
|
6987
|
-
assetId: string;
|
|
6988
|
-
productId: string;
|
|
6989
|
-
variantId: string | null;
|
|
6990
|
-
fileName: string;
|
|
6991
|
-
contentType: string | null;
|
|
6992
|
-
sizeBytes: number | null;
|
|
6993
|
-
status: string;
|
|
6994
|
-
createdAt: string;
|
|
6995
|
-
}>;
|
|
6996
|
-
/** 판매 파일 목록 — 해제한 파일도 싣는다. 객체 키·주소는 없다 */
|
|
6997
|
-
listDigitalAssets: (productId: string) => Promise<{
|
|
6998
|
-
assetId: string;
|
|
6999
|
-
productId: string;
|
|
7000
|
-
variantId: string | null;
|
|
7001
|
-
fileName: string;
|
|
7002
|
-
contentType: string | null;
|
|
7003
|
-
sizeBytes: number | null;
|
|
7004
|
-
status: string;
|
|
7005
|
-
createdAt: string;
|
|
7006
|
-
}[]>;
|
|
7007
|
-
/** 판매 파일 해제 — 새 주문에 주지 않는다. 이미 산 구매자는 계속 받는다 */
|
|
7008
|
-
removeDigitalAsset: (productId: string, assetId: string) => Promise<{
|
|
7009
|
-
assetId: string;
|
|
7010
|
-
productId: string;
|
|
7011
|
-
variantId: string | null;
|
|
7012
|
-
fileName: string;
|
|
7013
|
-
contentType: string | null;
|
|
7014
|
-
sizeBytes: number | null;
|
|
7015
|
-
status: string;
|
|
7016
|
-
createdAt: string;
|
|
7017
|
-
}>;
|
|
7018
|
-
/** 판매 파일 확인 주소 — 수명 300초의 서명 주소 */
|
|
7019
|
-
previewDigitalAsset: (productId: string, assetId: string) => Promise<{
|
|
7020
|
-
url: string;
|
|
7021
|
-
expiresAt: string;
|
|
7022
|
-
}>;
|
|
7023
|
-
};
|
|
7024
|
-
fulfillmentCodes: {
|
|
7025
|
-
/**
|
|
7026
|
-
* 코드 평문 열람 — 콘솔에서 로그인한 OWNER·ADMIN만 된다(403 `INSUFFICIENT_ROLE`). 열람 기록과 감사 로그가 남는다.
|
|
7027
|
-
* 평문은 화면에 보인 뒤 저장하지 않는다
|
|
7028
|
-
*/
|
|
7029
|
-
reveal: (codeId: string) => Promise<{
|
|
7030
|
-
codeId: string;
|
|
7031
|
-
code: string;
|
|
7032
|
-
}>;
|
|
7033
7093
|
};
|
|
7034
7094
|
categories: {
|
|
7035
7095
|
list: (params?: {
|
|
@@ -7260,7 +7320,6 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7260
7320
|
updatedAt: string;
|
|
7261
7321
|
} | null;
|
|
7262
7322
|
};
|
|
7263
|
-
withdrawalAgreedAt: string | null;
|
|
7264
7323
|
testPayment: boolean;
|
|
7265
7324
|
items: {
|
|
7266
7325
|
orderItemId: string;
|
|
@@ -7279,29 +7338,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7279
7338
|
returnAddressId: string | null;
|
|
7280
7339
|
};
|
|
7281
7340
|
} | {
|
|
7282
|
-
type: "
|
|
7283
|
-
download: {
|
|
7284
|
-
limit: number;
|
|
7285
|
-
days: number;
|
|
7286
|
-
stockTracked: boolean;
|
|
7287
|
-
withdrawalRestricted: boolean;
|
|
7288
|
-
};
|
|
7289
|
-
} | {
|
|
7290
|
-
type: "CODE";
|
|
7291
|
-
code: {
|
|
7292
|
-
mode: string;
|
|
7293
|
-
withdrawalRestricted: boolean;
|
|
7294
|
-
};
|
|
7295
|
-
} | {
|
|
7296
|
-
type: "SERVICE";
|
|
7297
|
-
service: {
|
|
7298
|
-
mode: string;
|
|
7299
|
-
};
|
|
7300
|
-
} | {
|
|
7301
|
-
type: "PICKUP";
|
|
7302
|
-
pickup: {
|
|
7303
|
-
addressId: string | null;
|
|
7304
|
-
};
|
|
7341
|
+
type: "MANUAL";
|
|
7305
7342
|
};
|
|
7306
7343
|
quantity: number;
|
|
7307
7344
|
canceledQuantity: number;
|
|
@@ -7316,31 +7353,9 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7316
7353
|
} | null;
|
|
7317
7354
|
fulfillment: {
|
|
7318
7355
|
status: string;
|
|
7319
|
-
mode: string | null;
|
|
7320
7356
|
fulfilledAt: string;
|
|
7321
7357
|
note: string | null;
|
|
7322
|
-
|
|
7323
|
-
codeId: string;
|
|
7324
|
-
hint: string;
|
|
7325
|
-
status: string;
|
|
7326
|
-
revealedAt: string | null;
|
|
7327
|
-
}[];
|
|
7328
|
-
download: {
|
|
7329
|
-
count: number;
|
|
7330
|
-
limit: number;
|
|
7331
|
-
expiresAt: string | null;
|
|
7332
|
-
firstDownloadedAt: string | null;
|
|
7333
|
-
files: {
|
|
7334
|
-
assetId: string;
|
|
7335
|
-
fileName: string;
|
|
7336
|
-
sizeBytes: number | null;
|
|
7337
|
-
}[];
|
|
7338
|
-
} | null;
|
|
7339
|
-
mail: {
|
|
7340
|
-
status: string;
|
|
7341
|
-
sentAt: string | null;
|
|
7342
|
-
errorCode: string | null;
|
|
7343
|
-
} | null;
|
|
7358
|
+
mode?: string | undefined;
|
|
7344
7359
|
} | null;
|
|
7345
7360
|
autoDecisionDate: string | null;
|
|
7346
7361
|
sellerMemo: string | null;
|
|
@@ -7398,29 +7413,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7398
7413
|
returnAddressId: string | null;
|
|
7399
7414
|
};
|
|
7400
7415
|
} | {
|
|
7401
|
-
type: "
|
|
7402
|
-
download: {
|
|
7403
|
-
limit: number;
|
|
7404
|
-
days: number;
|
|
7405
|
-
stockTracked: boolean;
|
|
7406
|
-
withdrawalRestricted: boolean;
|
|
7407
|
-
};
|
|
7408
|
-
} | {
|
|
7409
|
-
type: "CODE";
|
|
7410
|
-
code: {
|
|
7411
|
-
mode: string;
|
|
7412
|
-
withdrawalRestricted: boolean;
|
|
7413
|
-
};
|
|
7414
|
-
} | {
|
|
7415
|
-
type: "SERVICE";
|
|
7416
|
-
service: {
|
|
7417
|
-
mode: string;
|
|
7418
|
-
};
|
|
7419
|
-
} | {
|
|
7420
|
-
type: "PICKUP";
|
|
7421
|
-
pickup: {
|
|
7422
|
-
addressId: string | null;
|
|
7423
|
-
};
|
|
7416
|
+
type: "MANUAL";
|
|
7424
7417
|
};
|
|
7425
7418
|
quantity: number;
|
|
7426
7419
|
canceledQuantity: number;
|
|
@@ -7435,31 +7428,9 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7435
7428
|
} | null;
|
|
7436
7429
|
fulfillment: {
|
|
7437
7430
|
status: string;
|
|
7438
|
-
mode: string | null;
|
|
7439
7431
|
fulfilledAt: string;
|
|
7440
7432
|
note: string | null;
|
|
7441
|
-
|
|
7442
|
-
codeId: string;
|
|
7443
|
-
hint: string;
|
|
7444
|
-
status: string;
|
|
7445
|
-
revealedAt: string | null;
|
|
7446
|
-
}[];
|
|
7447
|
-
download: {
|
|
7448
|
-
count: number;
|
|
7449
|
-
limit: number;
|
|
7450
|
-
expiresAt: string | null;
|
|
7451
|
-
firstDownloadedAt: string | null;
|
|
7452
|
-
files: {
|
|
7453
|
-
assetId: string;
|
|
7454
|
-
fileName: string;
|
|
7455
|
-
sizeBytes: number | null;
|
|
7456
|
-
}[];
|
|
7457
|
-
} | null;
|
|
7458
|
-
mail: {
|
|
7459
|
-
status: string;
|
|
7460
|
-
sentAt: string | null;
|
|
7461
|
-
errorCode: string | null;
|
|
7462
|
-
} | null;
|
|
7433
|
+
mode?: string | undefined;
|
|
7463
7434
|
} | null;
|
|
7464
7435
|
autoDecisionDate: string | null;
|
|
7465
7436
|
sellerMemo: string | null;
|
|
@@ -7545,29 +7516,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7545
7516
|
returnAddressId: string | null;
|
|
7546
7517
|
};
|
|
7547
7518
|
} | {
|
|
7548
|
-
type: "
|
|
7549
|
-
download: {
|
|
7550
|
-
limit: number;
|
|
7551
|
-
days: number;
|
|
7552
|
-
stockTracked: boolean;
|
|
7553
|
-
withdrawalRestricted: boolean;
|
|
7554
|
-
};
|
|
7555
|
-
} | {
|
|
7556
|
-
type: "CODE";
|
|
7557
|
-
code: {
|
|
7558
|
-
mode: string;
|
|
7559
|
-
withdrawalRestricted: boolean;
|
|
7560
|
-
};
|
|
7561
|
-
} | {
|
|
7562
|
-
type: "SERVICE";
|
|
7563
|
-
service: {
|
|
7564
|
-
mode: string;
|
|
7565
|
-
};
|
|
7566
|
-
} | {
|
|
7567
|
-
type: "PICKUP";
|
|
7568
|
-
pickup: {
|
|
7569
|
-
addressId: string | null;
|
|
7570
|
-
};
|
|
7519
|
+
type: "MANUAL";
|
|
7571
7520
|
};
|
|
7572
7521
|
quantity: number;
|
|
7573
7522
|
canceledQuantity: number;
|
|
@@ -7582,31 +7531,9 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7582
7531
|
} | null;
|
|
7583
7532
|
fulfillment: {
|
|
7584
7533
|
status: string;
|
|
7585
|
-
mode: string | null;
|
|
7586
7534
|
fulfilledAt: string;
|
|
7587
7535
|
note: string | null;
|
|
7588
|
-
|
|
7589
|
-
codeId: string;
|
|
7590
|
-
hint: string;
|
|
7591
|
-
status: string;
|
|
7592
|
-
revealedAt: string | null;
|
|
7593
|
-
}[];
|
|
7594
|
-
download: {
|
|
7595
|
-
count: number;
|
|
7596
|
-
limit: number;
|
|
7597
|
-
expiresAt: string | null;
|
|
7598
|
-
firstDownloadedAt: string | null;
|
|
7599
|
-
files: {
|
|
7600
|
-
assetId: string;
|
|
7601
|
-
fileName: string;
|
|
7602
|
-
sizeBytes: number | null;
|
|
7603
|
-
}[];
|
|
7604
|
-
} | null;
|
|
7605
|
-
mail: {
|
|
7606
|
-
status: string;
|
|
7607
|
-
sentAt: string | null;
|
|
7608
|
-
errorCode: string | null;
|
|
7609
|
-
} | null;
|
|
7536
|
+
mode?: string | undefined;
|
|
7610
7537
|
} | null;
|
|
7611
7538
|
autoDecisionDate: string | null;
|
|
7612
7539
|
sellerMemo: string | null;
|
|
@@ -7627,14 +7554,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7627
7554
|
}[];
|
|
7628
7555
|
}>;
|
|
7629
7556
|
/**
|
|
7630
|
-
* 제공
|
|
7631
|
-
* 코드·파일 주소는 메일에 없다
|
|
7632
|
-
*/
|
|
7633
|
-
resendFulfillmentMail: (orderItemId: string) => Promise<{
|
|
7634
|
-
mailStatus: string;
|
|
7635
|
-
}>;
|
|
7636
|
-
/**
|
|
7637
|
-
* 제공 처리 (이슈 #48) — 수동 제공 비실물 주문상품(이용권·방문 수령)을 `PAID`·`CONFIRMED`에서 제공 완료(`DELIVERED`)로
|
|
7557
|
+
* 제공 처리 (이슈 #48) — 배송 없는 주문상품(`MANUAL`)을 `PAID`·`CONFIRMED`에서 제공 완료(`DELIVERED`)로
|
|
7638
7558
|
* 바꾼다. `note`는 구매자 주문 상세에 이용 안내로 실린다. 배송 상품은 409 `SHIPPING_REQUIRED`
|
|
7639
7559
|
*/
|
|
7640
7560
|
fulfill: (orderItemId: string, body?: FulfillRequest, idempotencyKey?: string) => Promise<{
|
|
@@ -7654,29 +7574,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7654
7574
|
returnAddressId: string | null;
|
|
7655
7575
|
};
|
|
7656
7576
|
} | {
|
|
7657
|
-
type: "
|
|
7658
|
-
download: {
|
|
7659
|
-
limit: number;
|
|
7660
|
-
days: number;
|
|
7661
|
-
stockTracked: boolean;
|
|
7662
|
-
withdrawalRestricted: boolean;
|
|
7663
|
-
};
|
|
7664
|
-
} | {
|
|
7665
|
-
type: "CODE";
|
|
7666
|
-
code: {
|
|
7667
|
-
mode: string;
|
|
7668
|
-
withdrawalRestricted: boolean;
|
|
7669
|
-
};
|
|
7670
|
-
} | {
|
|
7671
|
-
type: "SERVICE";
|
|
7672
|
-
service: {
|
|
7673
|
-
mode: string;
|
|
7674
|
-
};
|
|
7675
|
-
} | {
|
|
7676
|
-
type: "PICKUP";
|
|
7677
|
-
pickup: {
|
|
7678
|
-
addressId: string | null;
|
|
7679
|
-
};
|
|
7577
|
+
type: "MANUAL";
|
|
7680
7578
|
};
|
|
7681
7579
|
quantity: number;
|
|
7682
7580
|
canceledQuantity: number;
|
|
@@ -7689,34 +7587,12 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
7689
7587
|
reason: string;
|
|
7690
7588
|
expectedDispatchDate: string;
|
|
7691
7589
|
} | null;
|
|
7692
|
-
fulfillment: {
|
|
7693
|
-
status: string;
|
|
7694
|
-
|
|
7695
|
-
|
|
7696
|
-
|
|
7697
|
-
|
|
7698
|
-
codeId: string;
|
|
7699
|
-
hint: string;
|
|
7700
|
-
status: string;
|
|
7701
|
-
revealedAt: string | null;
|
|
7702
|
-
}[];
|
|
7703
|
-
download: {
|
|
7704
|
-
count: number;
|
|
7705
|
-
limit: number;
|
|
7706
|
-
expiresAt: string | null;
|
|
7707
|
-
firstDownloadedAt: string | null;
|
|
7708
|
-
files: {
|
|
7709
|
-
assetId: string;
|
|
7710
|
-
fileName: string;
|
|
7711
|
-
sizeBytes: number | null;
|
|
7712
|
-
}[];
|
|
7713
|
-
} | null;
|
|
7714
|
-
mail: {
|
|
7715
|
-
status: string;
|
|
7716
|
-
sentAt: string | null;
|
|
7717
|
-
errorCode: string | null;
|
|
7718
|
-
} | null;
|
|
7719
|
-
} | null;
|
|
7590
|
+
fulfillment: {
|
|
7591
|
+
status: string;
|
|
7592
|
+
fulfilledAt: string;
|
|
7593
|
+
note: string | null;
|
|
7594
|
+
mode?: string | undefined;
|
|
7595
|
+
} | null;
|
|
7720
7596
|
autoDecisionDate: string | null;
|
|
7721
7597
|
sellerMemo: string | null;
|
|
7722
7598
|
orderedAt: string;
|
|
@@ -9969,7 +9845,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
9969
9845
|
list: (params?: ApprovalListOptions) => Promise<{
|
|
9970
9846
|
items: {
|
|
9971
9847
|
approvalId: string;
|
|
9972
|
-
status: "
|
|
9848
|
+
status: "PENDING" | "FAILED" | "SUCCEEDED" | "EXECUTING" | "UNKNOWN" | "REJECTED" | "EXPIRED";
|
|
9973
9849
|
operationId: string;
|
|
9974
9850
|
method: string;
|
|
9975
9851
|
path: string;
|
|
@@ -10019,7 +9895,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10019
9895
|
}>;
|
|
10020
9896
|
get: (approvalId: string) => Promise<{
|
|
10021
9897
|
approvalId: string;
|
|
10022
|
-
status: "
|
|
9898
|
+
status: "PENDING" | "FAILED" | "SUCCEEDED" | "EXECUTING" | "UNKNOWN" | "REJECTED" | "EXPIRED";
|
|
10023
9899
|
operationId: string;
|
|
10024
9900
|
method: string;
|
|
10025
9901
|
path: string;
|
|
@@ -10071,7 +9947,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10071
9947
|
*/
|
|
10072
9948
|
approve: (approvalId: string, body?: ApprovalDecisionRequest) => Promise<{
|
|
10073
9949
|
approvalId: string;
|
|
10074
|
-
status: "
|
|
9950
|
+
status: "PENDING" | "FAILED" | "SUCCEEDED" | "EXECUTING" | "UNKNOWN" | "REJECTED" | "EXPIRED";
|
|
10075
9951
|
operationId: string;
|
|
10076
9952
|
method: string;
|
|
10077
9953
|
path: string;
|
|
@@ -10119,7 +9995,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10119
9995
|
}>;
|
|
10120
9996
|
reject: (approvalId: string, body?: ApprovalDecisionRequest) => Promise<{
|
|
10121
9997
|
approvalId: string;
|
|
10122
|
-
status: "
|
|
9998
|
+
status: "PENDING" | "FAILED" | "SUCCEEDED" | "EXECUTING" | "UNKNOWN" | "REJECTED" | "EXPIRED";
|
|
10123
9999
|
operationId: string;
|
|
10124
10000
|
method: string;
|
|
10125
10001
|
path: string;
|
|
@@ -10216,7 +10092,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10216
10092
|
sellerAddresses: {
|
|
10217
10093
|
list: (type?: AddressType) => Promise<{
|
|
10218
10094
|
addressId: string;
|
|
10219
|
-
type: "SHIPPING" | "
|
|
10095
|
+
type: "SHIPPING" | "RETURN";
|
|
10220
10096
|
name: string;
|
|
10221
10097
|
isDefault: boolean;
|
|
10222
10098
|
contactName: string;
|
|
@@ -10231,6 +10107,777 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10231
10107
|
remove: (addressId: string) => Promise<void>;
|
|
10232
10108
|
setDefault: (addressId: string) => Promise<void>;
|
|
10233
10109
|
};
|
|
10110
|
+
/**
|
|
10111
|
+
* 스토어프론트 호스팅 (이슈 #53) — 조회 `storefront:r`, 쓰기 `storefront:rw`(OWNER·ADMIN).
|
|
10112
|
+
* 쓰기 응답은 바뀐 사이트다. Cloudflare 반영은 커밋 뒤라 `provisioning.status`가 잠시 `PENDING`일 수 있다.
|
|
10113
|
+
* 에이전트 토큰의 발행·되돌리기·템플릿 변경·공개 전환·슬러그 변경·끄기는 승인 대기(`ApprovalPendingError`)다.
|
|
10114
|
+
*/
|
|
10115
|
+
storefront: {
|
|
10116
|
+
/** `GET /v1/storefront/templates` — 템플릿 카탈로그 */
|
|
10117
|
+
listTemplates: () => Promise<{
|
|
10118
|
+
templateId: string;
|
|
10119
|
+
name: string;
|
|
10120
|
+
industry: string;
|
|
10121
|
+
description: string;
|
|
10122
|
+
thumbnailUrl: string | null;
|
|
10123
|
+
version: string;
|
|
10124
|
+
isDefault: boolean;
|
|
10125
|
+
}[]>;
|
|
10126
|
+
/** `GET /v1/storefront/site` — 스위치 상태와 현재 사이트(없으면 `site: null`) */
|
|
10127
|
+
get: () => Promise<{
|
|
10128
|
+
enabled: boolean;
|
|
10129
|
+
domain: string;
|
|
10130
|
+
editingEnabled: boolean;
|
|
10131
|
+
site: {
|
|
10132
|
+
siteId: string;
|
|
10133
|
+
slug: string;
|
|
10134
|
+
hostname: string;
|
|
10135
|
+
url: string;
|
|
10136
|
+
domains: {
|
|
10137
|
+
hostname: string;
|
|
10138
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10139
|
+
status: "ACTIVE" | "HELD";
|
|
10140
|
+
isPrimary: boolean;
|
|
10141
|
+
holdUntil: string | null;
|
|
10142
|
+
}[];
|
|
10143
|
+
templateId: string;
|
|
10144
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10145
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10146
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10147
|
+
publishedVersion: {
|
|
10148
|
+
versionId: string;
|
|
10149
|
+
number: number;
|
|
10150
|
+
templateId: string;
|
|
10151
|
+
templateVersion: string;
|
|
10152
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10153
|
+
published: boolean;
|
|
10154
|
+
publishedAt: string | null;
|
|
10155
|
+
message: string | null;
|
|
10156
|
+
source: "TEMPLATE" | "EDIT";
|
|
10157
|
+
buildId: string | null;
|
|
10158
|
+
createdByType: string;
|
|
10159
|
+
createdAt: string;
|
|
10160
|
+
} | null;
|
|
10161
|
+
provisioning: {
|
|
10162
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10163
|
+
lastErrorCode: string | null;
|
|
10164
|
+
syncedAt: string | null;
|
|
10165
|
+
};
|
|
10166
|
+
editPreview: {
|
|
10167
|
+
hostname: string | null;
|
|
10168
|
+
};
|
|
10169
|
+
slugChangesRemaining: number;
|
|
10170
|
+
createdAt: string;
|
|
10171
|
+
updatedAt: string;
|
|
10172
|
+
} | null;
|
|
10173
|
+
}>;
|
|
10174
|
+
/** `GET /v1/storefront/slug-availability?slug=` — 슬러그를 쓸 수 있는가 */
|
|
10175
|
+
checkSlug: (slug: string) => Promise<{
|
|
10176
|
+
slug: string;
|
|
10177
|
+
available: boolean;
|
|
10178
|
+
reason: "RESERVED" | "INVALID" | "TAKEN" | "CURRENT" | null;
|
|
10179
|
+
}>;
|
|
10180
|
+
/** `POST /v1/storefront/site` (201) — 템플릿으로 사이트를 만들고 v1을 발행한다. 공개 상태는 오픈 준비 중이다 */
|
|
10181
|
+
create: (body: CreateStorefrontSiteRequest) => Promise<{
|
|
10182
|
+
siteId: string;
|
|
10183
|
+
slug: string;
|
|
10184
|
+
hostname: string;
|
|
10185
|
+
url: string;
|
|
10186
|
+
domains: {
|
|
10187
|
+
hostname: string;
|
|
10188
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10189
|
+
status: "ACTIVE" | "HELD";
|
|
10190
|
+
isPrimary: boolean;
|
|
10191
|
+
holdUntil: string | null;
|
|
10192
|
+
}[];
|
|
10193
|
+
templateId: string;
|
|
10194
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10195
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10196
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10197
|
+
publishedVersion: {
|
|
10198
|
+
versionId: string;
|
|
10199
|
+
number: number;
|
|
10200
|
+
templateId: string;
|
|
10201
|
+
templateVersion: string;
|
|
10202
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10203
|
+
published: boolean;
|
|
10204
|
+
publishedAt: string | null;
|
|
10205
|
+
message: string | null;
|
|
10206
|
+
source: "TEMPLATE" | "EDIT";
|
|
10207
|
+
buildId: string | null;
|
|
10208
|
+
createdByType: string;
|
|
10209
|
+
createdAt: string;
|
|
10210
|
+
} | null;
|
|
10211
|
+
provisioning: {
|
|
10212
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10213
|
+
lastErrorCode: string | null;
|
|
10214
|
+
syncedAt: string | null;
|
|
10215
|
+
};
|
|
10216
|
+
editPreview: {
|
|
10217
|
+
hostname: string | null;
|
|
10218
|
+
};
|
|
10219
|
+
slugChangesRemaining: number;
|
|
10220
|
+
createdAt: string;
|
|
10221
|
+
updatedAt: string;
|
|
10222
|
+
}>;
|
|
10223
|
+
/** `POST /v1/storefront/site/template` — 템플릿을 바꾼다. 새 버전을 만들고 기본으로 곧바로 발행한다 */
|
|
10224
|
+
changeTemplate: (body: ChangeStorefrontTemplateRequest) => Promise<{
|
|
10225
|
+
siteId: string;
|
|
10226
|
+
slug: string;
|
|
10227
|
+
hostname: string;
|
|
10228
|
+
url: string;
|
|
10229
|
+
domains: {
|
|
10230
|
+
hostname: string;
|
|
10231
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10232
|
+
status: "ACTIVE" | "HELD";
|
|
10233
|
+
isPrimary: boolean;
|
|
10234
|
+
holdUntil: string | null;
|
|
10235
|
+
}[];
|
|
10236
|
+
templateId: string;
|
|
10237
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10238
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10239
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10240
|
+
publishedVersion: {
|
|
10241
|
+
versionId: string;
|
|
10242
|
+
number: number;
|
|
10243
|
+
templateId: string;
|
|
10244
|
+
templateVersion: string;
|
|
10245
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10246
|
+
published: boolean;
|
|
10247
|
+
publishedAt: string | null;
|
|
10248
|
+
message: string | null;
|
|
10249
|
+
source: "TEMPLATE" | "EDIT";
|
|
10250
|
+
buildId: string | null;
|
|
10251
|
+
createdByType: string;
|
|
10252
|
+
createdAt: string;
|
|
10253
|
+
} | null;
|
|
10254
|
+
provisioning: {
|
|
10255
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10256
|
+
lastErrorCode: string | null;
|
|
10257
|
+
syncedAt: string | null;
|
|
10258
|
+
};
|
|
10259
|
+
editPreview: {
|
|
10260
|
+
hostname: string | null;
|
|
10261
|
+
};
|
|
10262
|
+
slugChangesRemaining: number;
|
|
10263
|
+
createdAt: string;
|
|
10264
|
+
updatedAt: string;
|
|
10265
|
+
}>;
|
|
10266
|
+
/** `GET /v1/storefront/site/versions` — 버전 목록(최신 먼저) */
|
|
10267
|
+
listVersions: () => Promise<{
|
|
10268
|
+
versionId: string;
|
|
10269
|
+
number: number;
|
|
10270
|
+
templateId: string;
|
|
10271
|
+
templateVersion: string;
|
|
10272
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10273
|
+
published: boolean;
|
|
10274
|
+
publishedAt: string | null;
|
|
10275
|
+
message: string | null;
|
|
10276
|
+
source: "TEMPLATE" | "EDIT";
|
|
10277
|
+
buildId: string | null;
|
|
10278
|
+
createdByType: string;
|
|
10279
|
+
createdAt: string;
|
|
10280
|
+
}[]>;
|
|
10281
|
+
/** `POST /v1/storefront/site/versions/{versionId}/publish` — 그 버전을 발행한다(이미 발행돼 있으면 그대로 200) */
|
|
10282
|
+
publish: (versionId: string, body?: PublishStorefrontVersionRequest) => Promise<{
|
|
10283
|
+
siteId: string;
|
|
10284
|
+
slug: string;
|
|
10285
|
+
hostname: string;
|
|
10286
|
+
url: string;
|
|
10287
|
+
domains: {
|
|
10288
|
+
hostname: string;
|
|
10289
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10290
|
+
status: "ACTIVE" | "HELD";
|
|
10291
|
+
isPrimary: boolean;
|
|
10292
|
+
holdUntil: string | null;
|
|
10293
|
+
}[];
|
|
10294
|
+
templateId: string;
|
|
10295
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10296
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10297
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10298
|
+
publishedVersion: {
|
|
10299
|
+
versionId: string;
|
|
10300
|
+
number: number;
|
|
10301
|
+
templateId: string;
|
|
10302
|
+
templateVersion: string;
|
|
10303
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10304
|
+
published: boolean;
|
|
10305
|
+
publishedAt: string | null;
|
|
10306
|
+
message: string | null;
|
|
10307
|
+
source: "TEMPLATE" | "EDIT";
|
|
10308
|
+
buildId: string | null;
|
|
10309
|
+
createdByType: string;
|
|
10310
|
+
createdAt: string;
|
|
10311
|
+
} | null;
|
|
10312
|
+
provisioning: {
|
|
10313
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10314
|
+
lastErrorCode: string | null;
|
|
10315
|
+
syncedAt: string | null;
|
|
10316
|
+
};
|
|
10317
|
+
editPreview: {
|
|
10318
|
+
hostname: string | null;
|
|
10319
|
+
};
|
|
10320
|
+
slugChangesRemaining: number;
|
|
10321
|
+
createdAt: string;
|
|
10322
|
+
updatedAt: string;
|
|
10323
|
+
}>;
|
|
10324
|
+
/** `POST /v1/storefront/site/rollback` — 이전 발행 버전으로 되돌린다(재빌드 없음) */
|
|
10325
|
+
rollback: (body?: RollbackStorefrontRequest) => Promise<{
|
|
10326
|
+
siteId: string;
|
|
10327
|
+
slug: string;
|
|
10328
|
+
hostname: string;
|
|
10329
|
+
url: string;
|
|
10330
|
+
domains: {
|
|
10331
|
+
hostname: string;
|
|
10332
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10333
|
+
status: "ACTIVE" | "HELD";
|
|
10334
|
+
isPrimary: boolean;
|
|
10335
|
+
holdUntil: string | null;
|
|
10336
|
+
}[];
|
|
10337
|
+
templateId: string;
|
|
10338
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10339
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10340
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10341
|
+
publishedVersion: {
|
|
10342
|
+
versionId: string;
|
|
10343
|
+
number: number;
|
|
10344
|
+
templateId: string;
|
|
10345
|
+
templateVersion: string;
|
|
10346
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10347
|
+
published: boolean;
|
|
10348
|
+
publishedAt: string | null;
|
|
10349
|
+
message: string | null;
|
|
10350
|
+
source: "TEMPLATE" | "EDIT";
|
|
10351
|
+
buildId: string | null;
|
|
10352
|
+
createdByType: string;
|
|
10353
|
+
createdAt: string;
|
|
10354
|
+
} | null;
|
|
10355
|
+
provisioning: {
|
|
10356
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10357
|
+
lastErrorCode: string | null;
|
|
10358
|
+
syncedAt: string | null;
|
|
10359
|
+
};
|
|
10360
|
+
editPreview: {
|
|
10361
|
+
hostname: string | null;
|
|
10362
|
+
};
|
|
10363
|
+
slugChangesRemaining: number;
|
|
10364
|
+
createdAt: string;
|
|
10365
|
+
updatedAt: string;
|
|
10366
|
+
}>;
|
|
10367
|
+
/** `PUT /v1/storefront/site/slug` — 슬러그를 바꾼다. 옛 슬러그는 90일 보류되고 새 주소로 301한다 */
|
|
10368
|
+
changeSlug: (body: ChangeStorefrontSlugRequest) => Promise<{
|
|
10369
|
+
siteId: string;
|
|
10370
|
+
slug: string;
|
|
10371
|
+
hostname: string;
|
|
10372
|
+
url: string;
|
|
10373
|
+
domains: {
|
|
10374
|
+
hostname: string;
|
|
10375
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10376
|
+
status: "ACTIVE" | "HELD";
|
|
10377
|
+
isPrimary: boolean;
|
|
10378
|
+
holdUntil: string | null;
|
|
10379
|
+
}[];
|
|
10380
|
+
templateId: string;
|
|
10381
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10382
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10383
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10384
|
+
publishedVersion: {
|
|
10385
|
+
versionId: string;
|
|
10386
|
+
number: number;
|
|
10387
|
+
templateId: string;
|
|
10388
|
+
templateVersion: string;
|
|
10389
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10390
|
+
published: boolean;
|
|
10391
|
+
publishedAt: string | null;
|
|
10392
|
+
message: string | null;
|
|
10393
|
+
source: "TEMPLATE" | "EDIT";
|
|
10394
|
+
buildId: string | null;
|
|
10395
|
+
createdByType: string;
|
|
10396
|
+
createdAt: string;
|
|
10397
|
+
} | null;
|
|
10398
|
+
provisioning: {
|
|
10399
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10400
|
+
lastErrorCode: string | null;
|
|
10401
|
+
syncedAt: string | null;
|
|
10402
|
+
};
|
|
10403
|
+
editPreview: {
|
|
10404
|
+
hostname: string | null;
|
|
10405
|
+
};
|
|
10406
|
+
slugChangesRemaining: number;
|
|
10407
|
+
createdAt: string;
|
|
10408
|
+
updatedAt: string;
|
|
10409
|
+
}>;
|
|
10410
|
+
/** `PUT /v1/storefront/site/visibility` — 오픈 준비 중 ↔ 공개 */
|
|
10411
|
+
setVisibility: (body: SetStorefrontVisibilityRequest) => Promise<{
|
|
10412
|
+
siteId: string;
|
|
10413
|
+
slug: string;
|
|
10414
|
+
hostname: string;
|
|
10415
|
+
url: string;
|
|
10416
|
+
domains: {
|
|
10417
|
+
hostname: string;
|
|
10418
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10419
|
+
status: "ACTIVE" | "HELD";
|
|
10420
|
+
isPrimary: boolean;
|
|
10421
|
+
holdUntil: string | null;
|
|
10422
|
+
}[];
|
|
10423
|
+
templateId: string;
|
|
10424
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10425
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10426
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10427
|
+
publishedVersion: {
|
|
10428
|
+
versionId: string;
|
|
10429
|
+
number: number;
|
|
10430
|
+
templateId: string;
|
|
10431
|
+
templateVersion: string;
|
|
10432
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10433
|
+
published: boolean;
|
|
10434
|
+
publishedAt: string | null;
|
|
10435
|
+
message: string | null;
|
|
10436
|
+
source: "TEMPLATE" | "EDIT";
|
|
10437
|
+
buildId: string | null;
|
|
10438
|
+
createdByType: string;
|
|
10439
|
+
createdAt: string;
|
|
10440
|
+
} | null;
|
|
10441
|
+
provisioning: {
|
|
10442
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10443
|
+
lastErrorCode: string | null;
|
|
10444
|
+
syncedAt: string | null;
|
|
10445
|
+
};
|
|
10446
|
+
editPreview: {
|
|
10447
|
+
hostname: string | null;
|
|
10448
|
+
};
|
|
10449
|
+
slugChangesRemaining: number;
|
|
10450
|
+
createdAt: string;
|
|
10451
|
+
updatedAt: string;
|
|
10452
|
+
}>;
|
|
10453
|
+
/**
|
|
10454
|
+
* `POST /v1/storefront/site/preview-link` — 오픈 준비 중인 사이트를 구성원이 볼 수 있는 5분짜리 링크.
|
|
10455
|
+
* 콘솔에서 로그인한 OWNER·ADMIN만 받는다
|
|
10456
|
+
*/
|
|
10457
|
+
createPreviewLink: (body?: CreateStorefrontPreviewLinkRequest) => Promise<{
|
|
10458
|
+
url: string;
|
|
10459
|
+
expiresAt: string;
|
|
10460
|
+
}>;
|
|
10461
|
+
/** `POST /v1/storefront/site/disable` — 호스팅을 끈다(사이트 `CLOSED`, 슬러그 90일 보류). 다시 만들 수 있다 */
|
|
10462
|
+
disable: (body: DisableStorefrontHostingRequest) => Promise<{
|
|
10463
|
+
siteId: string;
|
|
10464
|
+
slug: string;
|
|
10465
|
+
hostname: string;
|
|
10466
|
+
url: string;
|
|
10467
|
+
domains: {
|
|
10468
|
+
hostname: string;
|
|
10469
|
+
kind: "PLATFORM" | "CUSTOM";
|
|
10470
|
+
status: "ACTIVE" | "HELD";
|
|
10471
|
+
isPrimary: boolean;
|
|
10472
|
+
holdUntil: string | null;
|
|
10473
|
+
}[];
|
|
10474
|
+
templateId: string;
|
|
10475
|
+
sourceMode: "CUSTOM" | "MANAGED";
|
|
10476
|
+
status: "ACTIVE" | "SUSPENDED" | "CLOSED";
|
|
10477
|
+
visibility: "COMING_SOON" | "PUBLIC";
|
|
10478
|
+
publishedVersion: {
|
|
10479
|
+
versionId: string;
|
|
10480
|
+
number: number;
|
|
10481
|
+
templateId: string;
|
|
10482
|
+
templateVersion: string;
|
|
10483
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10484
|
+
published: boolean;
|
|
10485
|
+
publishedAt: string | null;
|
|
10486
|
+
message: string | null;
|
|
10487
|
+
source: "TEMPLATE" | "EDIT";
|
|
10488
|
+
buildId: string | null;
|
|
10489
|
+
createdByType: string;
|
|
10490
|
+
createdAt: string;
|
|
10491
|
+
} | null;
|
|
10492
|
+
provisioning: {
|
|
10493
|
+
status: "PENDING" | "FAILED" | "SYNCED";
|
|
10494
|
+
lastErrorCode: string | null;
|
|
10495
|
+
syncedAt: string | null;
|
|
10496
|
+
};
|
|
10497
|
+
editPreview: {
|
|
10498
|
+
hostname: string | null;
|
|
10499
|
+
};
|
|
10500
|
+
slugChangesRemaining: number;
|
|
10501
|
+
createdAt: string;
|
|
10502
|
+
updatedAt: string;
|
|
10503
|
+
}>;
|
|
10504
|
+
/** `GET /v1/storefront/site/editing` — 편집 환경 상태(열린 환경·동시 상한·미리보기 인증서) */
|
|
10505
|
+
getEditing: () => Promise<{
|
|
10506
|
+
enabled: boolean;
|
|
10507
|
+
session: {
|
|
10508
|
+
sessionId: string;
|
|
10509
|
+
status: "STARTING" | "RUNNING";
|
|
10510
|
+
startStage: string | null;
|
|
10511
|
+
startedAt: string;
|
|
10512
|
+
lastEditedAt: string | null;
|
|
10513
|
+
lastActiveAt: string;
|
|
10514
|
+
idleExpiresAt: string;
|
|
10515
|
+
closesAt: string;
|
|
10516
|
+
} | null;
|
|
10517
|
+
capacity: {
|
|
10518
|
+
limit: number;
|
|
10519
|
+
inUse: number;
|
|
10520
|
+
};
|
|
10521
|
+
preview: {
|
|
10522
|
+
hostname: string | null;
|
|
10523
|
+
};
|
|
10524
|
+
workingTree: {
|
|
10525
|
+
modified: boolean;
|
|
10526
|
+
lastEditedAt: string | null;
|
|
10527
|
+
};
|
|
10528
|
+
}>;
|
|
10529
|
+
/**
|
|
10530
|
+
* `POST /v1/storefront/site/editing` — 편집 환경을 연다(이미 열려 있으면 그대로). 플랫폼 동시 상한에 걸리면 409
|
|
10531
|
+
* `EDIT_CAPACITY_FULL`(`details.retryAfterSeconds`). 띄우는 데 보통 30초가 걸린다(`session.status: STARTING`)
|
|
10532
|
+
*/
|
|
10533
|
+
startEditing: () => Promise<{
|
|
10534
|
+
enabled: boolean;
|
|
10535
|
+
session: {
|
|
10536
|
+
sessionId: string;
|
|
10537
|
+
status: "STARTING" | "RUNNING";
|
|
10538
|
+
startStage: string | null;
|
|
10539
|
+
startedAt: string;
|
|
10540
|
+
lastEditedAt: string | null;
|
|
10541
|
+
lastActiveAt: string;
|
|
10542
|
+
idleExpiresAt: string;
|
|
10543
|
+
closesAt: string;
|
|
10544
|
+
} | null;
|
|
10545
|
+
capacity: {
|
|
10546
|
+
limit: number;
|
|
10547
|
+
inUse: number;
|
|
10548
|
+
};
|
|
10549
|
+
preview: {
|
|
10550
|
+
hostname: string | null;
|
|
10551
|
+
};
|
|
10552
|
+
workingTree: {
|
|
10553
|
+
modified: boolean;
|
|
10554
|
+
lastEditedAt: string | null;
|
|
10555
|
+
};
|
|
10556
|
+
}>;
|
|
10557
|
+
/** `DELETE /v1/storefront/site/editing` — 편집 환경을 닫는다(작업 트리는 보존된다) */
|
|
10558
|
+
stopEditing: () => Promise<{
|
|
10559
|
+
enabled: boolean;
|
|
10560
|
+
session: {
|
|
10561
|
+
sessionId: string;
|
|
10562
|
+
status: "STARTING" | "RUNNING";
|
|
10563
|
+
startStage: string | null;
|
|
10564
|
+
startedAt: string;
|
|
10565
|
+
lastEditedAt: string | null;
|
|
10566
|
+
lastActiveAt: string;
|
|
10567
|
+
idleExpiresAt: string;
|
|
10568
|
+
closesAt: string;
|
|
10569
|
+
} | null;
|
|
10570
|
+
capacity: {
|
|
10571
|
+
limit: number;
|
|
10572
|
+
inUse: number;
|
|
10573
|
+
};
|
|
10574
|
+
preview: {
|
|
10575
|
+
hostname: string | null;
|
|
10576
|
+
};
|
|
10577
|
+
workingTree: {
|
|
10578
|
+
modified: boolean;
|
|
10579
|
+
lastEditedAt: string | null;
|
|
10580
|
+
};
|
|
10581
|
+
}>;
|
|
10582
|
+
/**
|
|
10583
|
+
* `POST /v1/storefront/site/editing/preview-link` — 편집 미리보기(dev 서버) 5분짜리 링크.
|
|
10584
|
+
* 콘솔에서 로그인한 OWNER·ADMIN만 받는다(에이전트 불가)
|
|
10585
|
+
*/
|
|
10586
|
+
createEditPreviewLink: (body?: CreateStorefrontEditPreviewLinkRequest) => Promise<{
|
|
10587
|
+
url: string;
|
|
10588
|
+
expiresAt: string;
|
|
10589
|
+
}>;
|
|
10590
|
+
/** `GET /v1/storefront/site/files?prefix=` — 작업 트리 파일 목록 */
|
|
10591
|
+
listFiles: (params?: {
|
|
10592
|
+
prefix?: string;
|
|
10593
|
+
}) => Promise<{
|
|
10594
|
+
files: {
|
|
10595
|
+
path: string;
|
|
10596
|
+
size: number;
|
|
10597
|
+
hash: string;
|
|
10598
|
+
}[];
|
|
10599
|
+
totalBytes: number;
|
|
10600
|
+
}>;
|
|
10601
|
+
/** `GET /v1/storefront/site/files/content?path=` — 파일 하나 읽기 */
|
|
10602
|
+
readFile: (filePath: string) => Promise<{
|
|
10603
|
+
path: string;
|
|
10604
|
+
content: string;
|
|
10605
|
+
encoding: "utf8" | "base64";
|
|
10606
|
+
hash: string;
|
|
10607
|
+
size: number;
|
|
10608
|
+
}>;
|
|
10609
|
+
/**
|
|
10610
|
+
* `POST /v1/storefront/site/files/batch` — 여러 파일 쓰기(해시 조건). 조건이 하나라도 어긋나면 아무것도 쓰지 않고 409
|
|
10611
|
+
* `FILE_CHANGED`(`details.conflicts`). 편집 환경이 없으면 연다
|
|
10612
|
+
*/
|
|
10613
|
+
writeFiles: (body: WriteStorefrontFilesRequest) => Promise<{
|
|
10614
|
+
files: {
|
|
10615
|
+
path: string;
|
|
10616
|
+
size: number;
|
|
10617
|
+
hash: string;
|
|
10618
|
+
}[];
|
|
10619
|
+
}>;
|
|
10620
|
+
/** `POST /v1/storefront/site/files/delete` */
|
|
10621
|
+
deleteFile: (body: DeleteStorefrontFileRequest) => Promise<{
|
|
10622
|
+
path: string;
|
|
10623
|
+
deleted: boolean;
|
|
10624
|
+
}>;
|
|
10625
|
+
/** `POST /v1/storefront/site/files/move` */
|
|
10626
|
+
moveFile: (body: MoveStorefrontFileRequest) => Promise<{
|
|
10627
|
+
from: string;
|
|
10628
|
+
to: string;
|
|
10629
|
+
hash: string;
|
|
10630
|
+
size: number;
|
|
10631
|
+
}>;
|
|
10632
|
+
/** `POST /v1/storefront/site/files/search` — 내용 검색 */
|
|
10633
|
+
searchFiles: (body: SearchStorefrontFilesRequest) => Promise<{
|
|
10634
|
+
matches: {
|
|
10635
|
+
path: string;
|
|
10636
|
+
line: number;
|
|
10637
|
+
text: string;
|
|
10638
|
+
column?: number | undefined;
|
|
10639
|
+
}[];
|
|
10640
|
+
truncated: boolean;
|
|
10641
|
+
}>;
|
|
10642
|
+
/**
|
|
10643
|
+
* `POST /v1/storefront/site/checks` (202) — 타입 검사·lint·test 하나를 시작한다. 결과는 `getCheck`로 끝날 때까지 조회한다
|
|
10644
|
+
* (`STOREFRONT_CHECK_TERMINAL_STATUSES`)
|
|
10645
|
+
*/
|
|
10646
|
+
runCheck: (body: RunStorefrontCheckRequest) => Promise<{
|
|
10647
|
+
checkId: string;
|
|
10648
|
+
check: string;
|
|
10649
|
+
status: "FAILED" | "UNKNOWN" | "RUNNING" | "QUEUED" | "PASSED" | "TIMED_OUT";
|
|
10650
|
+
exitCode: number | null;
|
|
10651
|
+
durationMs: number | null;
|
|
10652
|
+
outputTail: string | null;
|
|
10653
|
+
errorCode: string | null;
|
|
10654
|
+
message: string | null;
|
|
10655
|
+
createdAt: string;
|
|
10656
|
+
startedAt: string | null;
|
|
10657
|
+
finishedAt: string | null;
|
|
10658
|
+
}>;
|
|
10659
|
+
/** `GET /v1/storefront/site/checks/{checkId}` — 검사 상태·종료 코드·출력 꼬리 */
|
|
10660
|
+
getCheck: (checkId: string) => Promise<{
|
|
10661
|
+
checkId: string;
|
|
10662
|
+
check: string;
|
|
10663
|
+
status: "FAILED" | "UNKNOWN" | "RUNNING" | "QUEUED" | "PASSED" | "TIMED_OUT";
|
|
10664
|
+
exitCode: number | null;
|
|
10665
|
+
durationMs: number | null;
|
|
10666
|
+
outputTail: string | null;
|
|
10667
|
+
errorCode: string | null;
|
|
10668
|
+
message: string | null;
|
|
10669
|
+
createdAt: string;
|
|
10670
|
+
startedAt: string | null;
|
|
10671
|
+
finishedAt: string | null;
|
|
10672
|
+
}>;
|
|
10673
|
+
/** `POST /v1/storefront/site/verify` — 작업 트리 규칙 검증(`verify_storefront`와 같은 보고서) */
|
|
10674
|
+
verify: () => Promise<{
|
|
10675
|
+
ok: boolean;
|
|
10676
|
+
checkedFiles: number;
|
|
10677
|
+
summary: {
|
|
10678
|
+
rules: number;
|
|
10679
|
+
passed: number;
|
|
10680
|
+
violated: number;
|
|
10681
|
+
findings: number;
|
|
10682
|
+
};
|
|
10683
|
+
results: {
|
|
10684
|
+
ruleId: string;
|
|
10685
|
+
status: "pass" | "violation";
|
|
10686
|
+
count: number;
|
|
10687
|
+
severity?: "error" | "warning" | undefined;
|
|
10688
|
+
}[];
|
|
10689
|
+
findings: {
|
|
10690
|
+
ruleId: string;
|
|
10691
|
+
rule: string;
|
|
10692
|
+
file: string;
|
|
10693
|
+
detail: string;
|
|
10694
|
+
cause: string;
|
|
10695
|
+
fix: string;
|
|
10696
|
+
example: string;
|
|
10697
|
+
doc: string;
|
|
10698
|
+
docUrl: string;
|
|
10699
|
+
line?: number | undefined;
|
|
10700
|
+
templateFile?: string | undefined;
|
|
10701
|
+
severity?: "error" | "warning" | undefined;
|
|
10702
|
+
}[];
|
|
10703
|
+
message: string;
|
|
10704
|
+
nextSteps: string[];
|
|
10705
|
+
}>;
|
|
10706
|
+
/**
|
|
10707
|
+
* `POST /v1/storefront/site/versions` (201) — 지금 작업 트리로 버전을 만든다(빌드 시작). 버전은 `BUILDING`, 빌드가
|
|
10708
|
+
* 끝나면 `READY` 또는 `FAILED`다
|
|
10709
|
+
*/
|
|
10710
|
+
createVersion: (body?: CreateStorefrontVersionRequest) => Promise<{
|
|
10711
|
+
version: {
|
|
10712
|
+
versionId: string;
|
|
10713
|
+
number: number;
|
|
10714
|
+
templateId: string;
|
|
10715
|
+
templateVersion: string;
|
|
10716
|
+
status: "FAILED" | "BUILDING" | "READY";
|
|
10717
|
+
published: boolean;
|
|
10718
|
+
publishedAt: string | null;
|
|
10719
|
+
message: string | null;
|
|
10720
|
+
source: "TEMPLATE" | "EDIT";
|
|
10721
|
+
buildId: string | null;
|
|
10722
|
+
createdByType: string;
|
|
10723
|
+
createdAt: string;
|
|
10724
|
+
};
|
|
10725
|
+
build: {
|
|
10726
|
+
buildId: string;
|
|
10727
|
+
versionId: string;
|
|
10728
|
+
versionNumber: number;
|
|
10729
|
+
status: "FAILED" | "SUCCEEDED" | "RUNNING" | "QUEUED" | "TIMED_OUT";
|
|
10730
|
+
failureStage: string | null;
|
|
10731
|
+
errorCode: string | null;
|
|
10732
|
+
logTail: string | null;
|
|
10733
|
+
stages: {
|
|
10734
|
+
stage: string;
|
|
10735
|
+
ok: boolean;
|
|
10736
|
+
durationMs: number;
|
|
10737
|
+
}[];
|
|
10738
|
+
verify: {
|
|
10739
|
+
ok: boolean;
|
|
10740
|
+
checkedFiles: number;
|
|
10741
|
+
summary: {
|
|
10742
|
+
rules: number;
|
|
10743
|
+
passed: number;
|
|
10744
|
+
violated: number;
|
|
10745
|
+
findings: number;
|
|
10746
|
+
};
|
|
10747
|
+
results: {
|
|
10748
|
+
ruleId: string;
|
|
10749
|
+
status: "pass" | "violation";
|
|
10750
|
+
count: number;
|
|
10751
|
+
severity?: "error" | "warning" | undefined;
|
|
10752
|
+
}[];
|
|
10753
|
+
findings: {
|
|
10754
|
+
ruleId: string;
|
|
10755
|
+
rule: string;
|
|
10756
|
+
file: string;
|
|
10757
|
+
detail: string;
|
|
10758
|
+
cause: string;
|
|
10759
|
+
fix: string;
|
|
10760
|
+
example: string;
|
|
10761
|
+
doc: string;
|
|
10762
|
+
docUrl: string;
|
|
10763
|
+
line?: number | undefined;
|
|
10764
|
+
templateFile?: string | undefined;
|
|
10765
|
+
severity?: "error" | "warning" | undefined;
|
|
10766
|
+
}[];
|
|
10767
|
+
message: string;
|
|
10768
|
+
nextSteps: string[];
|
|
10769
|
+
} | null;
|
|
10770
|
+
queuedAt: string;
|
|
10771
|
+
startedAt: string | null;
|
|
10772
|
+
finishedAt: string | null;
|
|
10773
|
+
durationMs: number | null;
|
|
10774
|
+
};
|
|
10775
|
+
}>;
|
|
10776
|
+
/** `GET /v1/storefront/site/builds?limit=` — 빌드 목록(최신 먼저) */
|
|
10777
|
+
listBuilds: (params?: {
|
|
10778
|
+
limit?: number;
|
|
10779
|
+
}) => Promise<{
|
|
10780
|
+
buildId: string;
|
|
10781
|
+
versionId: string;
|
|
10782
|
+
versionNumber: number;
|
|
10783
|
+
status: "FAILED" | "SUCCEEDED" | "RUNNING" | "QUEUED" | "TIMED_OUT";
|
|
10784
|
+
failureStage: string | null;
|
|
10785
|
+
errorCode: string | null;
|
|
10786
|
+
logTail: string | null;
|
|
10787
|
+
stages: {
|
|
10788
|
+
stage: string;
|
|
10789
|
+
ok: boolean;
|
|
10790
|
+
durationMs: number;
|
|
10791
|
+
}[];
|
|
10792
|
+
verify: {
|
|
10793
|
+
ok: boolean;
|
|
10794
|
+
checkedFiles: number;
|
|
10795
|
+
summary: {
|
|
10796
|
+
rules: number;
|
|
10797
|
+
passed: number;
|
|
10798
|
+
violated: number;
|
|
10799
|
+
findings: number;
|
|
10800
|
+
};
|
|
10801
|
+
results: {
|
|
10802
|
+
ruleId: string;
|
|
10803
|
+
status: "pass" | "violation";
|
|
10804
|
+
count: number;
|
|
10805
|
+
severity?: "error" | "warning" | undefined;
|
|
10806
|
+
}[];
|
|
10807
|
+
findings: {
|
|
10808
|
+
ruleId: string;
|
|
10809
|
+
rule: string;
|
|
10810
|
+
file: string;
|
|
10811
|
+
detail: string;
|
|
10812
|
+
cause: string;
|
|
10813
|
+
fix: string;
|
|
10814
|
+
example: string;
|
|
10815
|
+
doc: string;
|
|
10816
|
+
docUrl: string;
|
|
10817
|
+
line?: number | undefined;
|
|
10818
|
+
templateFile?: string | undefined;
|
|
10819
|
+
severity?: "error" | "warning" | undefined;
|
|
10820
|
+
}[];
|
|
10821
|
+
message: string;
|
|
10822
|
+
nextSteps: string[];
|
|
10823
|
+
} | null;
|
|
10824
|
+
queuedAt: string;
|
|
10825
|
+
startedAt: string | null;
|
|
10826
|
+
finishedAt: string | null;
|
|
10827
|
+
durationMs: number | null;
|
|
10828
|
+
}[]>;
|
|
10829
|
+
/** `GET /v1/storefront/site/builds/{buildId}` — 빌드 상태·실패 단계·로그 꼬리·규칙 결과 */
|
|
10830
|
+
getBuild: (buildId: string) => Promise<{
|
|
10831
|
+
buildId: string;
|
|
10832
|
+
versionId: string;
|
|
10833
|
+
versionNumber: number;
|
|
10834
|
+
status: "FAILED" | "SUCCEEDED" | "RUNNING" | "QUEUED" | "TIMED_OUT";
|
|
10835
|
+
failureStage: string | null;
|
|
10836
|
+
errorCode: string | null;
|
|
10837
|
+
logTail: string | null;
|
|
10838
|
+
stages: {
|
|
10839
|
+
stage: string;
|
|
10840
|
+
ok: boolean;
|
|
10841
|
+
durationMs: number;
|
|
10842
|
+
}[];
|
|
10843
|
+
verify: {
|
|
10844
|
+
ok: boolean;
|
|
10845
|
+
checkedFiles: number;
|
|
10846
|
+
summary: {
|
|
10847
|
+
rules: number;
|
|
10848
|
+
passed: number;
|
|
10849
|
+
violated: number;
|
|
10850
|
+
findings: number;
|
|
10851
|
+
};
|
|
10852
|
+
results: {
|
|
10853
|
+
ruleId: string;
|
|
10854
|
+
status: "pass" | "violation";
|
|
10855
|
+
count: number;
|
|
10856
|
+
severity?: "error" | "warning" | undefined;
|
|
10857
|
+
}[];
|
|
10858
|
+
findings: {
|
|
10859
|
+
ruleId: string;
|
|
10860
|
+
rule: string;
|
|
10861
|
+
file: string;
|
|
10862
|
+
detail: string;
|
|
10863
|
+
cause: string;
|
|
10864
|
+
fix: string;
|
|
10865
|
+
example: string;
|
|
10866
|
+
doc: string;
|
|
10867
|
+
docUrl: string;
|
|
10868
|
+
line?: number | undefined;
|
|
10869
|
+
templateFile?: string | undefined;
|
|
10870
|
+
severity?: "error" | "warning" | undefined;
|
|
10871
|
+
}[];
|
|
10872
|
+
message: string;
|
|
10873
|
+
nextSteps: string[];
|
|
10874
|
+
} | null;
|
|
10875
|
+
queuedAt: string;
|
|
10876
|
+
startedAt: string | null;
|
|
10877
|
+
finishedAt: string | null;
|
|
10878
|
+
durationMs: number | null;
|
|
10879
|
+
}>;
|
|
10880
|
+
};
|
|
10234
10881
|
store: {
|
|
10235
10882
|
get: () => Promise<{
|
|
10236
10883
|
storeId: string;
|
|
@@ -10244,8 +10891,6 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10244
10891
|
analyticsAllowedOrigins: string[];
|
|
10245
10892
|
storefrontOrigins: string[];
|
|
10246
10893
|
guestCheckoutEnabled: boolean;
|
|
10247
|
-
fulfillmentMailEnabled: boolean;
|
|
10248
|
-
withdrawalNotice: string | null;
|
|
10249
10894
|
autoDeliverDays: number;
|
|
10250
10895
|
autoConfirmDays: number;
|
|
10251
10896
|
refundPolicy: {
|
|
@@ -10287,8 +10932,6 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10287
10932
|
analyticsAllowedOrigins: string[];
|
|
10288
10933
|
storefrontOrigins: string[];
|
|
10289
10934
|
guestCheckoutEnabled: boolean;
|
|
10290
|
-
fulfillmentMailEnabled: boolean;
|
|
10291
|
-
withdrawalNotice: string | null;
|
|
10292
10935
|
autoDeliverDays: number;
|
|
10293
10936
|
autoConfirmDays: number;
|
|
10294
10937
|
refundPolicy: {
|
|
@@ -10318,7 +10961,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10318
10961
|
userId: string;
|
|
10319
10962
|
name: string;
|
|
10320
10963
|
email: string;
|
|
10321
|
-
role: "
|
|
10964
|
+
role: "ADMIN" | "STAFF" | "OWNER";
|
|
10322
10965
|
joinedAt: string;
|
|
10323
10966
|
lastActiveAt: string | null;
|
|
10324
10967
|
}[]>;
|
|
@@ -10335,7 +10978,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10335
10978
|
invitationId: string;
|
|
10336
10979
|
email: string;
|
|
10337
10980
|
role: "ADMIN" | "STAFF";
|
|
10338
|
-
status: "
|
|
10981
|
+
status: "PENDING" | "EXPIRED" | "ACCEPTED" | "CANCELED";
|
|
10339
10982
|
invitedBy: string;
|
|
10340
10983
|
expiresAt: string;
|
|
10341
10984
|
createdAt: string;
|
|
@@ -10353,7 +10996,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10353
10996
|
invitationId: string;
|
|
10354
10997
|
email: string;
|
|
10355
10998
|
role: "ADMIN" | "STAFF";
|
|
10356
|
-
status: "
|
|
10999
|
+
status: "PENDING" | "EXPIRED" | "ACCEPTED" | "CANCELED";
|
|
10357
11000
|
invitedBy: string;
|
|
10358
11001
|
expiresAt: string;
|
|
10359
11002
|
createdAt: string;
|
|
@@ -10368,7 +11011,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
|
|
|
10368
11011
|
invitationId: string;
|
|
10369
11012
|
email: string;
|
|
10370
11013
|
role: "ADMIN" | "STAFF";
|
|
10371
|
-
status: "
|
|
11014
|
+
status: "PENDING" | "EXPIRED" | "ACCEPTED" | "CANCELED";
|
|
10372
11015
|
invitedBy: string;
|
|
10373
11016
|
expiresAt: string;
|
|
10374
11017
|
createdAt: string;
|
|
@@ -10880,6 +11523,7 @@ export declare const STORE_SCOPE_RESOURCES: {
|
|
|
10880
11523
|
readonly customer: readonly ["r", "rw"];
|
|
10881
11524
|
readonly audit: readonly ["r"];
|
|
10882
11525
|
readonly promotion: readonly ["r", "rw"];
|
|
11526
|
+
readonly storefront: readonly ["r", "rw"];
|
|
10883
11527
|
};
|
|
10884
11528
|
export type StoreScopeResource = keyof typeof STORE_SCOPE_RESOURCES;
|
|
10885
11529
|
export declare const storeScopeResourceSchema: z.ZodEnum<{
|
|
@@ -10897,6 +11541,7 @@ export declare const storeScopeResourceSchema: z.ZodEnum<{
|
|
|
10897
11541
|
customer: "customer";
|
|
10898
11542
|
audit: "audit";
|
|
10899
11543
|
promotion: "promotion";
|
|
11544
|
+
storefront: "storefront";
|
|
10900
11545
|
}>;
|
|
10901
11546
|
/** 카탈로그상 존재하는 스코프 문자열인가 (예: `settlement:rw`는 false) */
|
|
10902
11547
|
export declare function isStoreScope(scope: string): boolean;
|
|
@@ -10906,8 +11551,8 @@ export declare function isStoreScope(scope: string): boolean;
|
|
|
10906
11551
|
* 발급 시 지정한 스코프만 갖는다(발급자 보유 스코프 이내).
|
|
10907
11552
|
*/
|
|
10908
11553
|
export declare const STORE_ROLE_SCOPES: {
|
|
10909
|
-
readonly OWNER: readonly ["product:rw", "category:rw", "order:rw", "claim:rw", "inquiry:rw", "review:rw", "settlement:r", "analytics:r", "webhook:rw", "store:rw", "member:rw", "customer:rw", "audit:r", "promotion:rw"];
|
|
10910
|
-
readonly ADMIN: readonly ["product:rw", "category:rw", "order:rw", "claim:rw", "inquiry:rw", "review:rw", "analytics:r", "webhook:rw", "store:rw", "member:rw", "customer:rw", "audit:r", "promotion:rw"];
|
|
11554
|
+
readonly OWNER: readonly ["product:rw", "category:rw", "order:rw", "claim:rw", "inquiry:rw", "review:rw", "settlement:r", "analytics:r", "webhook:rw", "store:rw", "member:rw", "customer:rw", "audit:r", "promotion:rw", "storefront:rw"];
|
|
11555
|
+
readonly ADMIN: readonly ["product:rw", "category:rw", "order:rw", "claim:rw", "inquiry:rw", "review:rw", "analytics:r", "webhook:rw", "store:rw", "member:rw", "customer:rw", "audit:r", "promotion:rw", "storefront:rw"];
|
|
10911
11556
|
readonly STAFF: readonly ["product:rw", "category:rw", "order:rw", "claim:rw", "inquiry:rw", "review:rw", "customer:r", "promotion:r"];
|
|
10912
11557
|
};
|
|
10913
11558
|
//#endregion
|
|
@@ -11189,29 +11834,7 @@ export declare const orderWebhookEventDataSchema: z.ZodObject<{
|
|
|
11189
11834
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
11190
11835
|
}, z.core.$strip>;
|
|
11191
11836
|
}, z.core.$strip>, z.ZodObject<{
|
|
11192
|
-
type: z.ZodLiteral<"
|
|
11193
|
-
download: z.ZodObject<{
|
|
11194
|
-
limit: z.ZodNumber;
|
|
11195
|
-
days: z.ZodNumber;
|
|
11196
|
-
stockTracked: z.ZodBoolean;
|
|
11197
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11198
|
-
}, z.core.$strip>;
|
|
11199
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11200
|
-
type: z.ZodLiteral<"CODE">;
|
|
11201
|
-
code: z.ZodObject<{
|
|
11202
|
-
mode: z.ZodString;
|
|
11203
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11204
|
-
}, z.core.$strip>;
|
|
11205
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11206
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
11207
|
-
service: z.ZodObject<{
|
|
11208
|
-
mode: z.ZodString;
|
|
11209
|
-
}, z.core.$strip>;
|
|
11210
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11211
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
11212
|
-
pickup: z.ZodObject<{
|
|
11213
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
11214
|
-
}, z.core.$strip>;
|
|
11837
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
11215
11838
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
11216
11839
|
type: z.ZodString;
|
|
11217
11840
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -11221,9 +11844,8 @@ export declare const orderWebhookEventDataSchema: z.ZodObject<{
|
|
|
11221
11844
|
}, z.core.$strip>;
|
|
11222
11845
|
export type OrderWebhookEventData = z.infer<typeof orderWebhookEventDataSchema>;
|
|
11223
11846
|
/**
|
|
11224
|
-
* `ORDER.FULFILLED` —
|
|
11225
|
-
*
|
|
11226
|
-
* `ORDER.DELIVERED`도 함께 보낸다. **코드·파일 주소는 싣지 않는다** — 관리 API로 조회한다.
|
|
11847
|
+
* `ORDER.FULFILLED` — 배송 없는 주문상품(`MANUAL`)을 제공했다(이슈 #48). 셀러의 제공 처리
|
|
11848
|
+
* (`POST /v1/order-items/{orderItemId}/fulfill`)로 온다. 기존 구독자를 위해 같은 순간 `ORDER.DELIVERED`도 함께 보낸다.
|
|
11227
11849
|
*/
|
|
11228
11850
|
export declare const orderFulfilledWebhookEventDataSchema: z.ZodObject<{
|
|
11229
11851
|
orderId: z.ZodString;
|
|
@@ -11245,38 +11867,16 @@ export declare const orderFulfilledWebhookEventDataSchema: z.ZodObject<{
|
|
|
11245
11867
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
11246
11868
|
}, z.core.$strip>;
|
|
11247
11869
|
}, z.core.$strip>, z.ZodObject<{
|
|
11248
|
-
type: z.ZodLiteral<"
|
|
11249
|
-
download: z.ZodObject<{
|
|
11250
|
-
limit: z.ZodNumber;
|
|
11251
|
-
days: z.ZodNumber;
|
|
11252
|
-
stockTracked: z.ZodBoolean;
|
|
11253
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11254
|
-
}, z.core.$strip>;
|
|
11255
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11256
|
-
type: z.ZodLiteral<"CODE">;
|
|
11257
|
-
code: z.ZodObject<{
|
|
11258
|
-
mode: z.ZodString;
|
|
11259
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11260
|
-
}, z.core.$strip>;
|
|
11261
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11262
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
11263
|
-
service: z.ZodObject<{
|
|
11264
|
-
mode: z.ZodString;
|
|
11265
|
-
}, z.core.$strip>;
|
|
11266
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11267
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
11268
|
-
pickup: z.ZodObject<{
|
|
11269
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
11270
|
-
}, z.core.$strip>;
|
|
11870
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
11271
11871
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
11272
11872
|
type: z.ZodString;
|
|
11273
11873
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
11274
11874
|
[x: string]: unknown;
|
|
11275
11875
|
type: string;
|
|
11276
11876
|
}>>]>;
|
|
11277
|
-
fulfillment: z.ZodObject<{
|
|
11877
|
+
fulfillment: z.ZodOptional<z.ZodObject<{
|
|
11278
11878
|
mode: z.ZodString;
|
|
11279
|
-
}, z.core.$strip
|
|
11879
|
+
}, z.core.$strip>>;
|
|
11280
11880
|
fulfilledAt: z.ZodString;
|
|
11281
11881
|
testPayment: z.ZodBoolean;
|
|
11282
11882
|
}, z.core.$strip>;
|
|
@@ -11397,29 +11997,7 @@ export declare const orderWebhookEventSchema: z.ZodObject<{
|
|
|
11397
11997
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
11398
11998
|
}, z.core.$strip>;
|
|
11399
11999
|
}, z.core.$strip>, z.ZodObject<{
|
|
11400
|
-
type: z.ZodLiteral<"
|
|
11401
|
-
download: z.ZodObject<{
|
|
11402
|
-
limit: z.ZodNumber;
|
|
11403
|
-
days: z.ZodNumber;
|
|
11404
|
-
stockTracked: z.ZodBoolean;
|
|
11405
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11406
|
-
}, z.core.$strip>;
|
|
11407
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11408
|
-
type: z.ZodLiteral<"CODE">;
|
|
11409
|
-
code: z.ZodObject<{
|
|
11410
|
-
mode: z.ZodString;
|
|
11411
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11412
|
-
}, z.core.$strip>;
|
|
11413
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11414
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
11415
|
-
service: z.ZodObject<{
|
|
11416
|
-
mode: z.ZodString;
|
|
11417
|
-
}, z.core.$strip>;
|
|
11418
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11419
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
11420
|
-
pickup: z.ZodObject<{
|
|
11421
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
11422
|
-
}, z.core.$strip>;
|
|
12000
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
11423
12001
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
11424
12002
|
type: z.ZodString;
|
|
11425
12003
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -11454,38 +12032,16 @@ export declare const orderFulfilledWebhookEventSchema: z.ZodObject<{
|
|
|
11454
12032
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
11455
12033
|
}, z.core.$strip>;
|
|
11456
12034
|
}, z.core.$strip>, z.ZodObject<{
|
|
11457
|
-
type: z.ZodLiteral<"
|
|
11458
|
-
download: z.ZodObject<{
|
|
11459
|
-
limit: z.ZodNumber;
|
|
11460
|
-
days: z.ZodNumber;
|
|
11461
|
-
stockTracked: z.ZodBoolean;
|
|
11462
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11463
|
-
}, z.core.$strip>;
|
|
11464
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11465
|
-
type: z.ZodLiteral<"CODE">;
|
|
11466
|
-
code: z.ZodObject<{
|
|
11467
|
-
mode: z.ZodString;
|
|
11468
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11469
|
-
}, z.core.$strip>;
|
|
11470
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11471
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
11472
|
-
service: z.ZodObject<{
|
|
11473
|
-
mode: z.ZodString;
|
|
11474
|
-
}, z.core.$strip>;
|
|
11475
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11476
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
11477
|
-
pickup: z.ZodObject<{
|
|
11478
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
11479
|
-
}, z.core.$strip>;
|
|
12035
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
11480
12036
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
11481
12037
|
type: z.ZodString;
|
|
11482
12038
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
11483
12039
|
[x: string]: unknown;
|
|
11484
12040
|
type: string;
|
|
11485
12041
|
}>>]>;
|
|
11486
|
-
fulfillment: z.ZodObject<{
|
|
12042
|
+
fulfillment: z.ZodOptional<z.ZodObject<{
|
|
11487
12043
|
mode: z.ZodString;
|
|
11488
|
-
}, z.core.$strip
|
|
12044
|
+
}, z.core.$strip>>;
|
|
11489
12045
|
fulfilledAt: z.ZodString;
|
|
11490
12046
|
testPayment: z.ZodBoolean;
|
|
11491
12047
|
}, z.core.$strip>;
|
|
@@ -11641,29 +12197,7 @@ export declare const webhookEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
11641
12197
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
11642
12198
|
}, z.core.$strip>;
|
|
11643
12199
|
}, z.core.$strip>, z.ZodObject<{
|
|
11644
|
-
type: z.ZodLiteral<"
|
|
11645
|
-
download: z.ZodObject<{
|
|
11646
|
-
limit: z.ZodNumber;
|
|
11647
|
-
days: z.ZodNumber;
|
|
11648
|
-
stockTracked: z.ZodBoolean;
|
|
11649
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11650
|
-
}, z.core.$strip>;
|
|
11651
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11652
|
-
type: z.ZodLiteral<"CODE">;
|
|
11653
|
-
code: z.ZodObject<{
|
|
11654
|
-
mode: z.ZodString;
|
|
11655
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11656
|
-
}, z.core.$strip>;
|
|
11657
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11658
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
11659
|
-
service: z.ZodObject<{
|
|
11660
|
-
mode: z.ZodString;
|
|
11661
|
-
}, z.core.$strip>;
|
|
11662
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11663
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
11664
|
-
pickup: z.ZodObject<{
|
|
11665
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
11666
|
-
}, z.core.$strip>;
|
|
12200
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
11667
12201
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
11668
12202
|
type: z.ZodString;
|
|
11669
12203
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
@@ -11697,38 +12231,16 @@ export declare const webhookEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
|
11697
12231
|
returnAddressId: z.ZodNullable<z.ZodString>;
|
|
11698
12232
|
}, z.core.$strip>;
|
|
11699
12233
|
}, z.core.$strip>, z.ZodObject<{
|
|
11700
|
-
type: z.ZodLiteral<"
|
|
11701
|
-
download: z.ZodObject<{
|
|
11702
|
-
limit: z.ZodNumber;
|
|
11703
|
-
days: z.ZodNumber;
|
|
11704
|
-
stockTracked: z.ZodBoolean;
|
|
11705
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11706
|
-
}, z.core.$strip>;
|
|
11707
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11708
|
-
type: z.ZodLiteral<"CODE">;
|
|
11709
|
-
code: z.ZodObject<{
|
|
11710
|
-
mode: z.ZodString;
|
|
11711
|
-
withdrawalRestricted: z.ZodBoolean;
|
|
11712
|
-
}, z.core.$strip>;
|
|
11713
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11714
|
-
type: z.ZodLiteral<"SERVICE">;
|
|
11715
|
-
service: z.ZodObject<{
|
|
11716
|
-
mode: z.ZodString;
|
|
11717
|
-
}, z.core.$strip>;
|
|
11718
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
11719
|
-
type: z.ZodLiteral<"PICKUP">;
|
|
11720
|
-
pickup: z.ZodObject<{
|
|
11721
|
-
addressId: z.ZodNullable<z.ZodString>;
|
|
11722
|
-
}, z.core.$strip>;
|
|
12234
|
+
type: z.ZodLiteral<"MANUAL">;
|
|
11723
12235
|
}, z.core.$strip>], "type">, z.ZodPipe<z.ZodObject<{
|
|
11724
12236
|
type: z.ZodString;
|
|
11725
12237
|
}, z.core.$loose>, z.ZodTransform<UnknownFulfillment, {
|
|
11726
12238
|
[x: string]: unknown;
|
|
11727
12239
|
type: string;
|
|
11728
12240
|
}>>]>;
|
|
11729
|
-
fulfillment: z.ZodObject<{
|
|
12241
|
+
fulfillment: z.ZodOptional<z.ZodObject<{
|
|
11730
12242
|
mode: z.ZodString;
|
|
11731
|
-
}, z.core.$strip
|
|
12243
|
+
}, z.core.$strip>>;
|
|
11732
12244
|
fulfilledAt: z.ZodString;
|
|
11733
12245
|
testPayment: z.ZodBoolean;
|
|
11734
12246
|
}, z.core.$strip>;
|