@sayren/store-sdk 0.29.5 → 0.29.6
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 +150 -76
- package/dist/index.mjs +45 -6
- package/package.json +1 -1
- package/src/index.ts +1 -0
- package/src/schemas/claim.ts +4 -0
- package/src/schemas/commerce-number.ts +28 -0
- package/src/schemas/order.ts +29 -4
- package/src/schemas/payment.ts +21 -2
- package/src/schemas/product.ts +25 -0
- package/src/schemas/webhook-event.ts +32 -0
package/dist/index.mjs
CHANGED
|
@@ -730,6 +730,31 @@ const categoryListQuerySchema = z.object({
|
|
|
730
730
|
/** `DELETE /v1/categories/{categoryId}` 쿼리 — OpenAPI 문서용 형태 */
|
|
731
731
|
const categoryDeleteQuerySchema = z.object({ strategy: categoryDeleteStrategySchema.optional().describe("하위 카테고리·연결 상품 처리 방식. 생략하면 둘 중 하나라도 있을 때 409 `CATEGORY_NOT_EMPTY`다. `reparent`는 직계 자식을 삭제할 카테고리의 부모로 옮기고, `cascade`는 서브트리를 삭제하고 연결 상품을 미분류로 둔다") });
|
|
732
732
|
//#endregion
|
|
733
|
+
//#region src/schemas/commerce-number.ts
|
|
734
|
+
/**
|
|
735
|
+
* 국내 쇼핑몰 번호 체계(이슈 #107) — 공개 ID(`ord_…` 등)와 따로 싣는 숫자 번호의 표기·필드.
|
|
736
|
+
* 번호는 서버가 만들고 생성 후 바뀌지 않는다. 새 필드라 옛 서버 응답에는 없다 — 파싱은 null로 채운다.
|
|
737
|
+
*/
|
|
738
|
+
/**
|
|
739
|
+
* 번호 표기 — 숫자를 앞에서부터 4자리씩 하이픈으로 나눈다. 주문번호 `26100284731592` → `2610-0284-7315-92`,
|
|
740
|
+
* 상품주문번호 `2610028473159201` → `2610-0284-7315-9201`. 숫자만으로 된 값이 아니면(클레임번호 `C…`) 그대로, 없으면 빈 문자열이다.
|
|
741
|
+
* 화면 표기 전용이다 — API에 보낼 때는 원래 값을 쓴다(주문번호 조회는 하이픈도 받는다)
|
|
742
|
+
*/
|
|
743
|
+
function formatOrderNo(no) {
|
|
744
|
+
if (!no) return "";
|
|
745
|
+
if (!/^\d+$/.test(no)) return no;
|
|
746
|
+
return no.match(/.{1,4}/g)?.join("-") ?? no;
|
|
747
|
+
}
|
|
748
|
+
/** 표기 하이픈·공백을 지운 숫자 번호. 숫자가 아닌 글자가 남거나 비면 null */
|
|
749
|
+
function parseOrderNo(value) {
|
|
750
|
+
const digits = value.replace(/[\s-]/g, "");
|
|
751
|
+
return /^\d+$/.test(digits) ? digits : null;
|
|
752
|
+
}
|
|
753
|
+
/** 응답 번호 필드 — 서버는 항상 싣고, 번호 체계 이전 행(백필 전)·옛 서버 응답은 null이다 */
|
|
754
|
+
function commerceNumberField(description) {
|
|
755
|
+
return z.string().nullable().optional().default(null).describe(description);
|
|
756
|
+
}
|
|
757
|
+
//#endregion
|
|
733
758
|
//#region src/schemas/common.ts
|
|
734
759
|
const pageInfoSchema = z.object({
|
|
735
760
|
page: z.number().int(),
|
|
@@ -826,6 +851,7 @@ const claimReturnAddressSchema = z.object({
|
|
|
826
851
|
});
|
|
827
852
|
const claimSchema = z.object({
|
|
828
853
|
claimId: z.string(),
|
|
854
|
+
claimNo: commerceNumberField("클레임번호(이슈 #107) — `C` + YYMMDD(KST) + 숫자 8자리. 취소·반품·교환 접수 단위 번호이고 생성 후 바뀌지 않습니다"),
|
|
829
855
|
type: claimTypeSchema,
|
|
830
856
|
status: claimStatusSchema,
|
|
831
857
|
orderId: z.string(),
|
|
@@ -1545,6 +1571,7 @@ const productStatusSchema = z.enum([
|
|
|
1545
1571
|
]);
|
|
1546
1572
|
const productSummarySchema = z.object({
|
|
1547
1573
|
productId: z.string(),
|
|
1574
|
+
productNo: z.number().int().nullable().optional().default(null).describe("상품번호(이슈 #107) — 상점별 1부터 증가하는 숫자, 상점 안에서 유일, 생성 후 바뀌지 않으며 지운 상품의 번호는 다시 쓰지 않습니다. URL에 써도 됩니다(스토어프론트 상품 상세 경로가 받습니다). 번호 체계 이전 응답은 null"),
|
|
1548
1575
|
name: z.string(),
|
|
1549
1576
|
status: productStatusSchema,
|
|
1550
1577
|
salePrice: z.number().int().describe("판매가. 원(KRW) 단위 정수"),
|
|
@@ -1578,6 +1605,7 @@ const optionGroupSchema = z.object({
|
|
|
1578
1605
|
*/
|
|
1579
1606
|
const productVariantSchema = z.object({
|
|
1580
1607
|
variantId: z.string(),
|
|
1608
|
+
variantNo: z.string().nullable().optional().default(null).describe("조합 번호(이슈 #107) — `{productNo}-{조합 순번 2자리}`(예: `10482-03`). 시스템이 매기는 SKU이고 상점 안에서 유일합니다(상품번호가 상점 범위라 다른 상점과는 겹칠 수 있습니다). 생성 후 바뀌지 않으며, 지운 조합의 번호는 다시 쓰지 않습니다. 셀러가 입력하는 `sku`와 별개입니다"),
|
|
1581
1609
|
/** 축 sortOrder 순서와 1:1 대응. 옵션 없는 상품은 [] */
|
|
1582
1610
|
valueIds: z.array(z.string()),
|
|
1583
1611
|
/** 값 이름을 " / "로 이은 파생 표시명. 옵션 없으면 "" */
|
|
@@ -1937,6 +1965,7 @@ const productListQuerySchema = z.object({
|
|
|
1937
1965
|
categoryId: z.string().optional().describe("카테고리 필터 — 하위 카테고리의 상품도 포함"),
|
|
1938
1966
|
keyword: z.string().optional().describe("상품명 검색 (포함)"),
|
|
1939
1967
|
sellerCode: z.string().optional().describe("판매자 상품코드 — 이 코드가 붙은 variant를 가진 상품"),
|
|
1968
|
+
productNo: z.string().optional().describe("상품번호(이슈 #107) — 이 상점의 그 번호 상품만. 숫자가 아니면 400 `INVALID_PARAMETER`"),
|
|
1940
1969
|
sort: productSortSchema.optional().describe("정렬 (기본 createdAt.desc)"),
|
|
1941
1970
|
...pageQueryShape()
|
|
1942
1971
|
});
|
|
@@ -3966,7 +3995,8 @@ const paymentRecordSchema = z.object({
|
|
|
3966
3995
|
environment: pgEnvironmentSchema.nullable().describe("결제 환경"),
|
|
3967
3996
|
testPayment: z.boolean().describe("샌드박스 결제인가"),
|
|
3968
3997
|
pgTransactionId: z.string().nullable().describe("PG 거래 id (토스 paymentKey, 포트원 txId)"),
|
|
3969
|
-
attemptId: z.string().nullable().describe("
|
|
3998
|
+
attemptId: z.string().nullable().describe("대표 시도 id. 번호 체계(이슈 #107) 이전 시도는 이 값을 PG 주문번호로 보냈습니다"),
|
|
3999
|
+
pgOrderId: z.string().nullable().optional().default(null).describe("PG에 보낸 주문번호(이슈 #107) — 토스페이먼츠 orderId·포트원 paymentId. 새 시도는 `{주문번호}-{시도 순번 2자리}`이고, 번호 체계 이전 시도는 시도 id(`attemptId`)와 같습니다. PG 관리자 화면에서 결제를 찾을 때 씁니다"),
|
|
3970
4000
|
attemptCount: z.number().int().describe("시도 횟수"),
|
|
3971
4001
|
failCode: z.string().nullable().describe("실패 코드. 실패로 끝난 결제만"),
|
|
3972
4002
|
failMessage: z.string().nullable().describe("실패 사유"),
|
|
@@ -3977,6 +4007,7 @@ const paymentRecordSchema = z.object({
|
|
|
3977
4007
|
const paymentRecordPageSchema = pageSchema(paymentRecordSchema);
|
|
3978
4008
|
const paymentAttemptRecordSchema = z.object({
|
|
3979
4009
|
attemptId: z.string(),
|
|
4010
|
+
pgOrderId: z.string().nullable().optional().default(null).describe("PG에 보낸 주문번호(이슈 #107) — 토스페이먼츠 orderId·포트원 paymentId. 새 시도는 `{주문번호}-{시도 순번 2자리}`이고, 번호 체계 이전 시도는 시도 id(`attemptId`)와 같습니다. PG 관리자 화면에서 결제를 찾을 때 씁니다"),
|
|
3980
4011
|
sequence: z.number().int().describe("결제 건 안에서의 순번 (1부터)"),
|
|
3981
4012
|
provider: pgProviderSchema,
|
|
3982
4013
|
status: paymentAttemptStatusSchema,
|
|
@@ -4017,7 +4048,7 @@ const paymentListQuerySchema = z.object({
|
|
|
4017
4048
|
status: z.string().optional().describe("결제 상태 필터 (PaymentRecordStatus)"),
|
|
4018
4049
|
provider: z.string().optional().describe("PG 필터"),
|
|
4019
4050
|
method: z.string().optional().describe("실제 결제수단 필터"),
|
|
4020
|
-
keyword: z.string().optional().describe("결제 id
|
|
4051
|
+
keyword: z.string().optional().describe("결제 id·주문 id·PG 거래 id·시도 id·PG 주문번호(일치), 구매자명(포함)"),
|
|
4021
4052
|
includeTest: z.string().optional().describe("테스트 결제 포함 여부 (`true`·`false`. 기본 false — 실결제만)"),
|
|
4022
4053
|
page: z.string().optional().describe("페이지 번호 (1부터)"),
|
|
4023
4054
|
size: z.string().optional().describe("페이지 크기 (기본 20, 최대 100)")
|
|
@@ -4026,6 +4057,7 @@ const paymentListQuerySchema = z.object({
|
|
|
4026
4057
|
//#region src/schemas/order.ts
|
|
4027
4058
|
const orderSummarySchema = z.object({
|
|
4028
4059
|
orderId: z.string(),
|
|
4060
|
+
orderNo: commerceNumberField("주문번호(이슈 #107) — 숫자 14자리(YYMMDD KST + 난수 8자리), 전역 유일, 생성 후 바뀌지 않습니다. 전화 CS·ARS용 번호이고 API 경로의 식별자는 여전히 `orderId`입니다. 화면 표기는 `formatOrderNo`(4자리 하이픈)를 쓰십시오"),
|
|
4029
4061
|
ordererName: z.string(),
|
|
4030
4062
|
itemCount: z.number().int(),
|
|
4031
4063
|
totalAmount: z.number().int(),
|
|
@@ -4051,6 +4083,7 @@ const orderItemFulfillmentSchema = z.object({
|
|
|
4051
4083
|
});
|
|
4052
4084
|
const orderItemSchema = z.object({
|
|
4053
4085
|
orderItemId: z.string(),
|
|
4086
|
+
orderItemNo: commerceNumberField("상품주문번호(이슈 #107) — 주문번호 + 줄 순번 2자리(01부터, 100줄부터 3자리). 부분 취소·클레임·송장의 처리 단위 번호이고 생성 후 바뀌지 않습니다"),
|
|
4054
4087
|
orderId: z.string(),
|
|
4055
4088
|
status: orderItemStatusSchema,
|
|
4056
4089
|
claimStatus: z.enum([
|
|
@@ -4096,6 +4129,7 @@ const orderDiscountSchema = z.object({
|
|
|
4096
4129
|
});
|
|
4097
4130
|
const orderSchema = z.object({
|
|
4098
4131
|
orderId: z.string(),
|
|
4132
|
+
orderNo: commerceNumberField("주문번호(이슈 #107) — 숫자 14자리(YYMMDD KST + 난수 8자리), 전역 유일, 생성 후 바뀌지 않습니다. 전화 CS·ARS용 번호이고 API 경로의 식별자는 여전히 `orderId`입니다. 화면 표기는 `formatOrderNo`(4자리 하이픈)를 쓰십시오"),
|
|
4099
4133
|
orderedAt: z.string(),
|
|
4100
4134
|
orderer: z.object({
|
|
4101
4135
|
name: z.string(),
|
|
@@ -4137,14 +4171,15 @@ const testPaymentQuery = z.enum(["true", "false"]).optional().describe("테스
|
|
|
4137
4171
|
const pageQuery = { page: z.string().optional().describe("페이지 번호 (1부터, 기본 1)") };
|
|
4138
4172
|
/**
|
|
4139
4173
|
* `GET /v1/orders` 쿼리 — OpenAPI 문서용 형태(값은 쿼리 문자열). 검증 규칙은 서버가 적용한다:
|
|
4140
|
-
* `orderedFrom` 누락 400 `MISSING_PARAMETER`,
|
|
4174
|
+
* `orderNo` 없이 `orderedFrom` 누락 400 `MISSING_PARAMETER`, 날짜·`orderNo` 형식 오류 400 `INVALID_PARAMETER`, 31일 초과 400 `RANGE_TOO_WIDE`,
|
|
4141
4175
|
* `testPayment`가 `true`·`false`가 아니면 400 `INVALID_PARAMETER`
|
|
4142
4176
|
*/
|
|
4143
4177
|
const orderListQuerySchema = z.object({
|
|
4144
|
-
orderedFrom: z.string().describe("조회 시작 시각 (ISO 8601 날짜 또는 일시, 포함). 필수"),
|
|
4178
|
+
orderedFrom: z.string().optional().describe("조회 시작 시각 (ISO 8601 날짜 또는 일시, 포함). `orderNo`가 없으면 필수"),
|
|
4145
4179
|
orderedTo: z.string().optional().describe("조회 끝 시각 (ISO 8601, 포함). 생략하면 orderedFrom부터 31일. 기간은 최대 31일"),
|
|
4146
4180
|
status: orderItemStatusSchema.optional().describe("주문상품 상태 필터 — 이 상태의 주문상품이 하나라도 있는 주문"),
|
|
4147
|
-
keyword: z.string().optional().describe("
|
|
4181
|
+
keyword: z.string().optional().describe("주문 id·주문번호(일치, 하이픈 허용)·주문자명·수령인명(포함) 검색"),
|
|
4182
|
+
orderNo: z.string().optional().describe("주문번호 조회(이슈 #107) — 숫자 14자리, 하이픈 허용(`2610-0284-7315-92`). 주면 기간 조건 없이 그 주문만 찾습니다. 형식이 아니면 400 `INVALID_PARAMETER`"),
|
|
4148
4183
|
fulfillmentType: z.string().optional().describe("상품 유형 필터(이슈 #48) — 이 유형(`SHIPPING`·`MANUAL`)의 주문상품이 하나라도 있는 주문"),
|
|
4149
4184
|
testPayment: testPaymentQuery,
|
|
4150
4185
|
...pageQuery,
|
|
@@ -7137,6 +7172,7 @@ const envelopeFields = {
|
|
|
7137
7172
|
};
|
|
7138
7173
|
const orderWebhookEventDataSchema = z.object({
|
|
7139
7174
|
orderId: z.string().describe("주문 ID"),
|
|
7175
|
+
orderNo: z.string().nullable().optional().default(null).describe("주문번호(이슈 #107) — 숫자 14자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 주문은 null로 읽는다"),
|
|
7140
7176
|
status: orderItemStatusSchema.describe("이벤트 발생 시점의 주문 대표 상태"),
|
|
7141
7177
|
testPayment: z.boolean().optional().default(false).describe("테스트 결제(샌드박스 결제) 주문인가. true면 실제로 돈이 오가지 않았다. 이 필드가 없는 이전 이벤트는 false로 읽는다"),
|
|
7142
7178
|
couponDiscountAmount: z.number().int().optional().default(0).describe("주문이 받은 상품·주문 쿠폰 할인 합계 (원). 즉시할인(`discountAmount`)과 별개다. 쿠폰이 없거나 이 필드가 없는 이전 이벤트는 0으로 읽는다"),
|
|
@@ -7155,6 +7191,7 @@ const orderWebhookEventDataSchema = z.object({
|
|
|
7155
7191
|
*/
|
|
7156
7192
|
const orderFulfilledWebhookEventDataSchema = z.object({
|
|
7157
7193
|
orderId: z.string().describe("주문 ID"),
|
|
7194
|
+
orderNo: z.string().nullable().optional().default(null).describe("주문번호(이슈 #107) — 숫자 14자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 주문은 null로 읽는다"),
|
|
7158
7195
|
orderItemId: z.string().describe("제공한 주문상품 ID"),
|
|
7159
7196
|
status: orderItemStatusSchema.describe("이벤트 발생 시점의 주문 대표 상태"),
|
|
7160
7197
|
fulfillmentSnapshot: orderItemFulfillmentSnapshotResponseSchema.describe("제공한 주문상품의 주문 시점 이행 스냅샷(주문상품 응답의 `fulfillmentSnapshot`과 같다, 이슈 #57)"),
|
|
@@ -7169,6 +7206,7 @@ const orderFulfilledWebhookEventDataSchema = z.object({
|
|
|
7169
7206
|
*/
|
|
7170
7207
|
const orderCanceledWebhookEventDataSchema = z.object({
|
|
7171
7208
|
orderId: z.string().describe("주문 ID"),
|
|
7209
|
+
orderNo: z.string().nullable().optional().default(null).describe("주문번호(이슈 #107) — 숫자 14자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 주문은 null로 읽는다"),
|
|
7172
7210
|
orderItemId: z.string().describe("취소한 주문 상품 ID"),
|
|
7173
7211
|
status: orderItemStatusSchema.describe("취소 뒤 주문 대표 상태. 모든 주문 상품이 취소됐으면 `CANCELED`다"),
|
|
7174
7212
|
itemStatus: orderItemStatusSchema.describe("취소 뒤 주문 상품 상태. 전 수량이 취소됐으면 `CANCELED`, 일부만 취소했으면 원래 상태다"),
|
|
@@ -7185,6 +7223,7 @@ const orderCanceledWebhookEventDataSchema = z.object({
|
|
|
7185
7223
|
});
|
|
7186
7224
|
const claimWebhookEventDataSchema = z.object({
|
|
7187
7225
|
claimId: z.string().describe("클레임 ID"),
|
|
7226
|
+
claimNo: z.string().nullable().optional().default(null).describe("클레임번호(이슈 #107) — `C` + YYMMDD + 숫자 8자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 클레임은 null로 읽는다"),
|
|
7188
7227
|
orderId: z.string().describe("주문 ID"),
|
|
7189
7228
|
orderItemId: z.string().describe("클레임 대상 주문 상품 ID"),
|
|
7190
7229
|
claimType: claimTypeSchema.describe("클레임 유형"),
|
|
@@ -7449,4 +7488,4 @@ function createStoreSession(options) {
|
|
|
7449
7488
|
};
|
|
7450
7489
|
}
|
|
7451
7490
|
//#endregion
|
|
7452
|
-
export { APPROVAL_ALREADY_DECIDED_CODE, APPROVAL_REQUIRED_CODE, ApiError, ApprovalPendingError, BUSINESS_INFO_MAX_LENGTH, BUSINESS_NUMBER_PATTERN, CASH_RECEIPT_STATUS_VALUES, COLLECTION_BEST_SELLING_DAYS, COLLECTION_PREVIEW_SIZE, COLLECTION_PRODUCT_SORTS, COLLECTION_SALES_SORT_DEFAULT_DAYS, COLLECTION_SLUG_PATTERN, COLLECTION_TYPES, COUPON_CODE_PATTERN, COUPON_CONDITIONS_DEFAULTS, COUPON_TARGET_ALL, COUPON_TARGET_LIST_MAX, CUSTOM_INPUT_FORBIDDEN_WORDS, FULFILLMENT_RULES, MAX_ADDON_GROUPS, MAX_ANALYTICS_ALLOWED_ORIGINS, MAX_AUTO_TRANSITION_DAYS, MAX_COLLECTIONS, MAX_COLLECTION_BEST_SELLING_TOP, MAX_COLLECTION_CREATED_WITHIN_DAYS, MAX_COLLECTION_DESCRIPTION, MAX_COLLECTION_PRODUCTS, MAX_COLLECTION_PRODUCTS_PER_ADD, MAX_COLLECTION_RULES, MAX_COLLECTION_RULE_CATEGORIES, MAX_COLLECTION_TITLE, MAX_CUSTOM_INPUTS, MAX_CUSTOM_INPUT_LENGTH, MAX_OPTION_GROUPS, MAX_PRODUCT_IMAGES, MAX_SAVED_OPTION_SETS, MAX_SAVED_OPTION_SET_NAME, MAX_VALUES_PER_GROUP, MAX_VARIANTS, MCP_TELEMETRY_MAX_RESULTS, MIN_PAYMENT_AMOUNT, NO_COUPON_SETTLEMENT, NO_SHIPPING_BUNDLE_KEY, PAYMENT_ROUTING_EXCLUSION_CODES, POINT_ADJUSTMENT_MAX, POINT_EARN_RATE_BP_MAX, POINT_ENTRY_TYPES, POINT_EXPIRY_DAYS_MAX, POINT_EXPIRY_DAYS_MIN, POINT_LOT_SOURCES, POINT_POLICY_DEFAULTS, POINT_REVIEW_REWARD_MAX, POINT_USE_UNITS, PORTONE_CHANNEL_NAME_MAX_LENGTH, PORTONE_MAX_CHANNELS, PORTONE_MIN_CHANNELS, REFUND_POLICY_DEFAULTS, REFUND_POLICY_DELIVERY_FEE_KEYS, REMOTE_AREA_ZIP_RANGES, RESERVED_STOREFRONT_SLUGS, RESERVED_STORE_CODES, SHIPPING_POLICY_DEFAULTS, STOREFRONT_BLOCKED_PATH_SEGMENTS, STOREFRONT_BUILD_STAGES, STOREFRONT_BUILD_TERMINAL_STATUSES, STOREFRONT_CHECK_TERMINAL_STATUSES, STOREFRONT_CUSTOM_DOMAIN_LIMIT_DEFAULT, STOREFRONT_DOMAIN_DNS_GRACE_DAYS, STOREFRONT_DOMAIN_DNS_WAIT_DAYS, STOREFRONT_DOMAIN_TXT_LABEL, STOREFRONT_EDIT_ACTIVITY_TIMEOUT_MINUTES, STOREFRONT_EDIT_CAPACITY, STOREFRONT_EDIT_IDLE_MINUTES, STOREFRONT_EDIT_PREVIEW_SUFFIX, STOREFRONT_EDIT_START_STAGES, STOREFRONT_FILE_BATCH_MAX, STOREFRONT_FILE_MAX_BYTES, STOREFRONT_PATH_SEGMENT_PATTERN, STOREFRONT_PLATFORM_DOMAINS, STOREFRONT_PUBLIC_SUFFIXES, STOREFRONT_SEARCH_REGEX_MAX_LENGTH, STOREFRONT_SHOWCASE_SLUG_PREFIX, STOREFRONT_SITE_CREATE_LIMIT, STOREFRONT_SLUG_CHANGE_LIMIT, STOREFRONT_SLUG_CHANGE_WINDOW_DAYS, STOREFRONT_SLUG_HOLD_DAYS, STOREFRONT_SLUG_PATTERN, STOREFRONT_SOURCE_BLOB_BATCH_MAX, STOREFRONT_SOURCE_PART_BYTES, STOREFRONT_WORKSPACE_MAX_BYTES, STOREFRONT_WORKSPACE_MAX_FILES, STORE_CODE_PATTERN, STORE_ROLE_SCOPES, STORE_SCOPE_RESOURCES, STORE_SESSION_KEYS, TOSS_WIDGET_CLIENT_KEY_PATTERN, TOSS_WIDGET_KEY_MESSAGE, TOSS_WIDGET_SECRET_KEY_PATTERN, UPLOAD_PURPOSE_LIMITS, VARIANT_COUNT_WARNING, VARIANT_STOCK_EXCLUSIVE_MESSAGE, WEBHOOK_DEFAULT_TOLERANCE_SEC, WEBHOOK_DELIVERY_ID_HEADER, WEBHOOK_EVENT_ID_HEADER, WEBHOOK_EVENT_TYPE_HEADER, WEBHOOK_FAILURE_REASONS, WEBHOOK_HEADERS, WEBHOOK_PAYLOAD_EXCERPT_MAX_BYTES, WEBHOOK_RESOURCE_TYPES, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_USER_AGENT, addStorefrontDomainRequestSchema, addonGroupRequestSchema, addonGroupSchema, addonValueRequestSchema, addonValueSchema, addressChangeRequestListSchema, addressTypeSchema, agentPolicyDecisionSchema, allocateByWeight, analyticsChannelSchema, analyticsCheckoutOutcomeSchema, analyticsCheckoutSchema, analyticsDeviceRowSchema, analyticsDevicesSchema, analyticsFunnelStepSchema, analyticsOriginSchema, analyticsOverviewSchema, analyticsPagesQuerySchema, analyticsPagesSchema, analyticsProductRowSchema, analyticsProductSortSchema, analyticsProductsQuerySchema, analyticsProductsSchema, analyticsRangeQuerySchema, analyticsRealtimeSchema, analyticsSearchQuerySchema, analyticsSearchSchema, analyticsSourceGroupBySchema, analyticsSourceRowSchema, analyticsSourcesQuerySchema, analyticsSourcesSchema, analyticsTotalsSchema, apiLogErrorSchema, apiLogListQuerySchema, apiLogPageSchema, apiLogPrincipalSchema, apiLogPrincipalTypeSchema, apiLogSchema, apiLogStatusFilterSchema, apiLogSummarySchema, approvalDecisionRequestSchema, approvalListQuerySchema, approvalPageSchema, approvalRequestSchema, approvalStatusSchema, approveClaimResultSchema, auditActorSchema, auditActorTypeSchema, auditLogListQuerySchema, auditLogOutcomeSchema, auditLogPageSchema, auditLogSchema, auditLogSourceSchema, bestSellingRuleOf, buildAuthorizeUrl, buildQuery, bulkResultSchema, businessInfoPatchShape, businessInfoResponseShape, businessNumberSchema, cancelBySellerRequestSchema, cancelBySellerResultSchema, carrierSchema, cashReceiptSchema, categoryAttributeSchema, categoryCreateRequestSchema, categoryDeleteQuerySchema, categoryDeleteStrategySchema, categoryListQuerySchema, categoryPatchRequestSchema, categoryProductSortSchema, categorySchema, categorySearchResultSchema, categoryTreeNodeSchema, categoryWithPathSchema, changeStorefrontSlugRequestSchema, changeStorefrontTemplateRequestSchema, changeTypeSchema, claimDetailSchema, claimHoldResultSchema, claimListQuerySchema, claimReasonSchema, claimReturnAddressSchema, claimSchema, claimStatusSchema, claimTypeSchema, claimWebhookEventDataSchema, claimWebhookEventSchema, collectionCreateRequestSchema, collectionListQuerySchema, collectionPageSchema, collectionPatchRequestSchema, collectionPreviewRequestSchema, collectionPreviewSchema, collectionProductListQuerySchema, collectionProductSchema, collectionProductSortRequestSchema, collectionProductsAddRequestSchema, collectionProductsReplaceRequestSchema, collectionRuleCategoryIds, collectionRuleSchema, collectionRuleViewSchema, collectionRulesPredicate, collectionRulesSchema, collectionSchema, collectionStateCountsSchema, collectionStateOf, collectionStateSchema, compareBySales, consentActionSchema, consentKindSchema, consentSourceSchema, couponBenefitSchema, couponConditionsInputSchema, couponConditionsSchema, couponDiscountOf, couponIssueListQuerySchema, couponIssueMethodSchema, couponIssueSchema, couponIssueStatusSchema, couponKindSchema, couponListQuerySchema, couponRedemptionListQuerySchema, couponRedemptionSchema, couponRejectReasonSchema, couponRuleSchema, couponSchema, couponStatsSchema, couponStatusSchema, couponTargetInputSchema, couponTargetSchema, createCouponRequestSchema, createPkcePair, createStoreClient, createStoreSession, createStorefrontEditPreviewLinkRequestSchema, createStorefrontPreviewLinkRequestSchema, createStorefrontSiteRequestSchema, createStorefrontVersionRequestSchema, customInputLabelForbiddenWord, customInputRequestSchema, customInputSchema, customInputValueSchema, customerAddressSchema, customerConsentListQuerySchema, customerConsentSchema, customerConsentStateSchema, customerConsentsSchema, customerCouponSchema, customerDelegationRequestSchema, customerDelegationSchema, customerDetailSchema, customerInquiryCategorySchema, customerInquiryListQuerySchema, customerListQuerySchema, customerOrderSchema, customerPointsSchema, customerSortSchema, customerStatsSchema, customerSummarySchema, customerWithdrawalBlockedDetailsSchema, deleteStorefrontFileRequestSchema, deliveryBundleKeyOf, deliveryFeeWaiverSchema, deliveryInfoSchema, deliveryMethodSchema, deliveryStatusSchema, deliveryTypeSchema, descendantCategoryIdsOf, disableStorefrontHostingRequestSchema, discountRequestSchema, discountSchema, dispatchRequestSchema, easyPayProviderResponseSchema, easyPayProviderSchema, eventTypeSchema, exchangeAuthorizationCode, fulfillBulkRequestSchema, fulfillRequestSchema, fulfillmentRuleOf, fulfillmentTypeOf, fulfillmentTypeResponseSchema, fulfillmentTypeSchema, holdOrderItemRequestSchema, inquiryListQuerySchema, inquirySchema, inquiryWebhookEventDataSchema, inquiryWebhookEventSchema, invitationDeliveryStatusSchema, invitationListQuerySchema, invitationSchema, inviteMemberRequestSchema, isCouponTargetLine, isEditableStorefrontPath, isReservedStoreCode, isReservedStorefrontSlug, isShowcaseStorefrontSlug, isStoreScope, isWebOrigin, issueCouponRequestSchema, issueCouponResultSchema, liveGateConditionCodeSchema, liveGateConditionSchema, liveGateErrorDetailsSchema, liveGateSchema, loginProviderSchema, loginProviderStatusSchema, loginProviderTestSchema, loginSettingsSchema, maskedSecretSchema, matchesCollectionRules, mcpRuleResultSchema, mcpToolEventSchema, moveStorefrontFileRequestSchema, myAccountSchema, myStoreSchema, normalizeBusinessNumber, normalizeCouponCode, normalizeStorefrontHostname, normalizeStorefrontPath, oauthTokenResponseSchema, openFulfillmentUnion, optionGroupKindSchema, optionGroupRequestSchema, optionGroupSchema, optionModelRequestSchema, optionModelSchema, optionSelectionSchema, optionSortSchema, optionValueRequestSchema, optionValueSchema, orderCanceledWebhookEventDataSchema, orderCanceledWebhookEventSchema, orderDiscountSchema, orderFulfilledWebhookEventDataSchema, orderFulfilledWebhookEventSchema, orderItemFulfillmentSchema, orderItemFulfillmentSnapshotResponseSchema, orderItemFulfillmentSnapshotSchema, orderItemListQuerySchema, orderItemMemoResultSchema, orderItemPageSchema, orderItemSchema, orderItemStatusSchema, orderListQuerySchema, orderSchema, orderSummaryPageSchema, orderSummarySchema, orderWebhookEventDataSchema, orderWebhookEventSchema, pageInfoSchema, pageQueryShape, pageSchema, paymentAttemptRecordSchema, paymentAttemptStatusSchema, paymentCredentialSetSchema, paymentFailureWarningSchema, paymentListQuerySchema, paymentProviderSchema, paymentProviderVerificationSchema, paymentRecordDetailSchema, paymentRecordPageSchema, paymentRecordSchema, paymentRecordStatusSchema, paymentRefundRecordSchema, paymentSettingsSchema, pgEnvironmentSchema, pgPaymentMethodSchema, pgProviderSchema, pgVerificationResultSchema, planCodeSchema, planEntitlementsSchema, planErrorDetailsSchema, pointAdjustmentRequestSchema, pointAdjustmentResultSchema, pointEarnOf, pointEarnRateBpSchema, pointEarningEnabled, pointEntrySchema, pointExpiresAtOf, pointHistoryQuerySchema, pointLotSchema, pointPolicyNoticeSchema, pointPolicySchema, pointRestoreExpiresAtOf, pointUseOf, pointUsePolicySchema, policyDocumentUrlSchema, policyVersionSchema, portOneChannelSchema, portOneCredentialsInputSchema, productCreateRequestSchema, productFulfillmentCreateSchema, productFulfillmentResponseSchema, productFulfillmentSchema, productFulfillmentUpdateSchema, productImageRejection, productImageUrlSchema, productListQuerySchema, productOutOfStockWebhookEventDataSchema, productOutOfStockWebhookEventSchema, productPatchRequestSchema, productRefundPolicyOverride, productRefundPolicyPatchSchema, productReplaceRequestSchema, productSchema, productSortSchema, productStatusSchema, productSummarySchema, productVariantRequestSchema, productVariantSchema, proratedPaidRefundBase, proratedPointRefund, proratedRefundBase, publicPlanSchema, publicPlansSchema, publishStorefrontVersionRequestSchema, purchaseDecisionExtendResultSchema, purchaseDecisionRequestResultSchema, purchaseEarnPolicySchema, purchaseEarnRateOf, quoteDelivery, quotePricing, rankBestSelling, refreshUserToken, refundPolicyPatchSchema, refundPolicySchema, rejectClaimRequestSchema, remoteAreaLabelOf, remoteAreaOf, remoteAreaSchema, remoteSurchargeOf, replaceStorefrontSourceRequestSchema, requiresCollection, requiresShipping, resolvePointPolicy, resolveRefundPolicy, resolveShippingPolicy, responsePlanCodeSchema, responsePointEntryTypeSchema, reviewListQuerySchema, reviewReportResultSchema, reviewRewardPointOf, reviewRewardPolicySchema, reviewSchema, reviewSortSchema, reviewWebhookEventDataSchema, reviewWebhookEventSchema, rollbackStorefrontRequestSchema, runStorefrontCheckRequestSchema, salesReportGroupBySchema, salesReportQuerySchema, salesReportRowSchema, salesReportSchema, salesTotalsSchema, saveLoginProviderRequestSchema, savedCustomInputRequestSchema, savedCustomInputSchema, savedOptionGroupRequestSchema, savedOptionGroupSchema, savedOptionSetCompositionSchema, savedOptionSetFromProductRequestSchema, savedOptionSetFromProductResultSchema, savedOptionSetListQuerySchema, savedOptionSetRequestSchema, savedOptionSetSchema, savedOptionSetSortSchema, savedOptionValueRequestSchema, savedOptionValueSchema, scopeAccessSchema, searchStorefrontFilesRequestSchema, sellerAddressListQuerySchema, sellerAddressRequestSchema, sellerAddressSchema, sellerCustomerInquirySchema, setStorefrontVisibilityRequestSchema, settleCouponShortfall, settlementDetailQuerySchema, settlementDetailSchema, settlementListQuerySchema, settlementStatusSchema, settlementSummarySchema, settlementWithDetailsSchema, shippingAddressSchema, shippingPolicyPatchSchema, shippingPolicySchema, splitRefund, storeCodeSchema, storeMemberRoleUpdatedSchema, storeMemberSchema, storePointPolicySchema, storeRoleSchema, storeSchema, storeScopeResourceSchema, storeSubscriptionSchema, storefrontBuildDependenciesSchema, storefrontBuildListQuerySchema, storefrontBuildSchema, storefrontBuildStatusSchema, storefrontCheckSchema, storefrontCheckStatusSchema, storefrontCustomDomainStatusSchema, storefrontCustomHostnameProblem, storefrontDependencyFindingSchema, storefrontDeploymentLogSchema, storefrontDeploymentSchema, storefrontDeploymentStepSchema, storefrontDnsRecordSchema, storefrontDomainSchema, storefrontDomainTxtNameOf, storefrontEditPreviewLabelOf, storefrontEditPreviewSchema, storefrontEditSessionSchema, storefrontEditSessionStatusSchema, storefrontEditingSchema, storefrontFileConflictDetailsSchema, storefrontFileContentQuerySchema, storefrontFileContentSchema, storefrontFileDeleteResultSchema, storefrontFileEncodingSchema, storefrontFileEntrySchema, storefrontFileHashSchema, storefrontFileListQuerySchema, storefrontFileListSchema, storefrontFileMoveResultSchema, storefrontFilePathSchema, storefrontFileSearchResultSchema, storefrontFileWriteResultSchema, storefrontHostingSchema, storefrontPreviewLinkSchema, storefrontProvisioningSchema, storefrontRuleResultSchema, storefrontRuleSeveritySchema, storefrontSiteDomainSchema, storefrontSiteDomainsSchema, storefrontSiteSchema, storefrontSiteStatusSchema, storefrontSlugAvailabilityQuerySchema, storefrontSlugAvailabilitySchema, storefrontSlugSchema, storefrontSourceArchivePartSchema, storefrontSourceArchiveQuerySchema, storefrontSourceBlobsResultSchema, storefrontSourceModeSchema, storefrontSourceRefSchema, storefrontSourceReplacedSchema, storefrontSourceSchema, storefrontSuspensionSchema, storefrontTemplateSchema, storefrontVerifyReportSchema, storefrontVersionCreatedSchema, storefrontVersionSchema, storefrontVersionStatusSchema, storefrontVisibilitySchema, subscriptionLimitsSchema, subscriptionStatusSchema, subscriptionUsageSchema, tossPaymentsCredentialsInputSchema, trackingStageResponseSchema, trackingUpdateResultSchema, updateCouponRequestSchema, updateLoginProviderRequestSchema, updateLoginSettingsRequestSchema, updateMemberRoleRequestSchema, updatePaymentProviderRequestSchema, updatePaymentSettingsRequestSchema, updatePointPolicyRequestSchema, updateStoreRequestSchema, uploadExtensionOf, uploadPurposeSchema, uploadRejection, uploadRequestSchema, uploadStorefrontSourceBlobsRequestSchema, uploadTicketSchema, upsertPortOneProviderRequestSchema, upsertTossPaymentsProviderRequestSchema, variantStockRequestSchema, variantStockSchema, verifyPaymentProviderRequestSchema, webhookCreatedSchema, webhookDeliveryDetailSchema, webhookDeliveryErrorCodeSchema, webhookDeliveryListQuerySchema, webhookDeliveryResourceSchema, webhookDeliverySchema, webhookDeliveryStatusSchema, webhookEventSchema, webhookFailureReasonSchema, webhookRedeliverFailedResultSchema, webhookRequestHeaderSchema, webhookRequestSchema, webhookResourceTypeSchema, webhookSchema, webhookSecretRotatedSchema, webhookStatusSchema, webhookTestRequestSchema, webhookTestResultSchema, withdrawCustomerRequestSchema, writeDryRunResultSchema, writePreviewSchema, writeStorefrontFilesRequestSchema };
|
|
7491
|
+
export { APPROVAL_ALREADY_DECIDED_CODE, APPROVAL_REQUIRED_CODE, ApiError, ApprovalPendingError, BUSINESS_INFO_MAX_LENGTH, BUSINESS_NUMBER_PATTERN, CASH_RECEIPT_STATUS_VALUES, COLLECTION_BEST_SELLING_DAYS, COLLECTION_PREVIEW_SIZE, COLLECTION_PRODUCT_SORTS, COLLECTION_SALES_SORT_DEFAULT_DAYS, COLLECTION_SLUG_PATTERN, COLLECTION_TYPES, COUPON_CODE_PATTERN, COUPON_CONDITIONS_DEFAULTS, COUPON_TARGET_ALL, COUPON_TARGET_LIST_MAX, CUSTOM_INPUT_FORBIDDEN_WORDS, FULFILLMENT_RULES, MAX_ADDON_GROUPS, MAX_ANALYTICS_ALLOWED_ORIGINS, MAX_AUTO_TRANSITION_DAYS, MAX_COLLECTIONS, MAX_COLLECTION_BEST_SELLING_TOP, MAX_COLLECTION_CREATED_WITHIN_DAYS, MAX_COLLECTION_DESCRIPTION, MAX_COLLECTION_PRODUCTS, MAX_COLLECTION_PRODUCTS_PER_ADD, MAX_COLLECTION_RULES, MAX_COLLECTION_RULE_CATEGORIES, MAX_COLLECTION_TITLE, MAX_CUSTOM_INPUTS, MAX_CUSTOM_INPUT_LENGTH, MAX_OPTION_GROUPS, MAX_PRODUCT_IMAGES, MAX_SAVED_OPTION_SETS, MAX_SAVED_OPTION_SET_NAME, MAX_VALUES_PER_GROUP, MAX_VARIANTS, MCP_TELEMETRY_MAX_RESULTS, MIN_PAYMENT_AMOUNT, NO_COUPON_SETTLEMENT, NO_SHIPPING_BUNDLE_KEY, PAYMENT_ROUTING_EXCLUSION_CODES, POINT_ADJUSTMENT_MAX, POINT_EARN_RATE_BP_MAX, POINT_ENTRY_TYPES, POINT_EXPIRY_DAYS_MAX, POINT_EXPIRY_DAYS_MIN, POINT_LOT_SOURCES, POINT_POLICY_DEFAULTS, POINT_REVIEW_REWARD_MAX, POINT_USE_UNITS, PORTONE_CHANNEL_NAME_MAX_LENGTH, PORTONE_MAX_CHANNELS, PORTONE_MIN_CHANNELS, REFUND_POLICY_DEFAULTS, REFUND_POLICY_DELIVERY_FEE_KEYS, REMOTE_AREA_ZIP_RANGES, RESERVED_STOREFRONT_SLUGS, RESERVED_STORE_CODES, SHIPPING_POLICY_DEFAULTS, STOREFRONT_BLOCKED_PATH_SEGMENTS, STOREFRONT_BUILD_STAGES, STOREFRONT_BUILD_TERMINAL_STATUSES, STOREFRONT_CHECK_TERMINAL_STATUSES, STOREFRONT_CUSTOM_DOMAIN_LIMIT_DEFAULT, STOREFRONT_DOMAIN_DNS_GRACE_DAYS, STOREFRONT_DOMAIN_DNS_WAIT_DAYS, STOREFRONT_DOMAIN_TXT_LABEL, STOREFRONT_EDIT_ACTIVITY_TIMEOUT_MINUTES, STOREFRONT_EDIT_CAPACITY, STOREFRONT_EDIT_IDLE_MINUTES, STOREFRONT_EDIT_PREVIEW_SUFFIX, STOREFRONT_EDIT_START_STAGES, STOREFRONT_FILE_BATCH_MAX, STOREFRONT_FILE_MAX_BYTES, STOREFRONT_PATH_SEGMENT_PATTERN, STOREFRONT_PLATFORM_DOMAINS, STOREFRONT_PUBLIC_SUFFIXES, STOREFRONT_SEARCH_REGEX_MAX_LENGTH, STOREFRONT_SHOWCASE_SLUG_PREFIX, STOREFRONT_SITE_CREATE_LIMIT, STOREFRONT_SLUG_CHANGE_LIMIT, STOREFRONT_SLUG_CHANGE_WINDOW_DAYS, STOREFRONT_SLUG_HOLD_DAYS, STOREFRONT_SLUG_PATTERN, STOREFRONT_SOURCE_BLOB_BATCH_MAX, STOREFRONT_SOURCE_PART_BYTES, STOREFRONT_WORKSPACE_MAX_BYTES, STOREFRONT_WORKSPACE_MAX_FILES, STORE_CODE_PATTERN, STORE_ROLE_SCOPES, STORE_SCOPE_RESOURCES, STORE_SESSION_KEYS, TOSS_WIDGET_CLIENT_KEY_PATTERN, TOSS_WIDGET_KEY_MESSAGE, TOSS_WIDGET_SECRET_KEY_PATTERN, UPLOAD_PURPOSE_LIMITS, VARIANT_COUNT_WARNING, VARIANT_STOCK_EXCLUSIVE_MESSAGE, WEBHOOK_DEFAULT_TOLERANCE_SEC, WEBHOOK_DELIVERY_ID_HEADER, WEBHOOK_EVENT_ID_HEADER, WEBHOOK_EVENT_TYPE_HEADER, WEBHOOK_FAILURE_REASONS, WEBHOOK_HEADERS, WEBHOOK_PAYLOAD_EXCERPT_MAX_BYTES, WEBHOOK_RESOURCE_TYPES, WEBHOOK_SIGNATURE_HEADER, WEBHOOK_USER_AGENT, addStorefrontDomainRequestSchema, addonGroupRequestSchema, addonGroupSchema, addonValueRequestSchema, addonValueSchema, addressChangeRequestListSchema, addressTypeSchema, agentPolicyDecisionSchema, allocateByWeight, analyticsChannelSchema, analyticsCheckoutOutcomeSchema, analyticsCheckoutSchema, analyticsDeviceRowSchema, analyticsDevicesSchema, analyticsFunnelStepSchema, analyticsOriginSchema, analyticsOverviewSchema, analyticsPagesQuerySchema, analyticsPagesSchema, analyticsProductRowSchema, analyticsProductSortSchema, analyticsProductsQuerySchema, analyticsProductsSchema, analyticsRangeQuerySchema, analyticsRealtimeSchema, analyticsSearchQuerySchema, analyticsSearchSchema, analyticsSourceGroupBySchema, analyticsSourceRowSchema, analyticsSourcesQuerySchema, analyticsSourcesSchema, analyticsTotalsSchema, apiLogErrorSchema, apiLogListQuerySchema, apiLogPageSchema, apiLogPrincipalSchema, apiLogPrincipalTypeSchema, apiLogSchema, apiLogStatusFilterSchema, apiLogSummarySchema, approvalDecisionRequestSchema, approvalListQuerySchema, approvalPageSchema, approvalRequestSchema, approvalStatusSchema, approveClaimResultSchema, auditActorSchema, auditActorTypeSchema, auditLogListQuerySchema, auditLogOutcomeSchema, auditLogPageSchema, auditLogSchema, auditLogSourceSchema, bestSellingRuleOf, buildAuthorizeUrl, buildQuery, bulkResultSchema, businessInfoPatchShape, businessInfoResponseShape, businessNumberSchema, cancelBySellerRequestSchema, cancelBySellerResultSchema, carrierSchema, cashReceiptSchema, categoryAttributeSchema, categoryCreateRequestSchema, categoryDeleteQuerySchema, categoryDeleteStrategySchema, categoryListQuerySchema, categoryPatchRequestSchema, categoryProductSortSchema, categorySchema, categorySearchResultSchema, categoryTreeNodeSchema, categoryWithPathSchema, changeStorefrontSlugRequestSchema, changeStorefrontTemplateRequestSchema, changeTypeSchema, claimDetailSchema, claimHoldResultSchema, claimListQuerySchema, claimReasonSchema, claimReturnAddressSchema, claimSchema, claimStatusSchema, claimTypeSchema, claimWebhookEventDataSchema, claimWebhookEventSchema, collectionCreateRequestSchema, collectionListQuerySchema, collectionPageSchema, collectionPatchRequestSchema, collectionPreviewRequestSchema, collectionPreviewSchema, collectionProductListQuerySchema, collectionProductSchema, collectionProductSortRequestSchema, collectionProductsAddRequestSchema, collectionProductsReplaceRequestSchema, collectionRuleCategoryIds, collectionRuleSchema, collectionRuleViewSchema, collectionRulesPredicate, collectionRulesSchema, collectionSchema, collectionStateCountsSchema, collectionStateOf, collectionStateSchema, commerceNumberField, compareBySales, consentActionSchema, consentKindSchema, consentSourceSchema, couponBenefitSchema, couponConditionsInputSchema, couponConditionsSchema, couponDiscountOf, couponIssueListQuerySchema, couponIssueMethodSchema, couponIssueSchema, couponIssueStatusSchema, couponKindSchema, couponListQuerySchema, couponRedemptionListQuerySchema, couponRedemptionSchema, couponRejectReasonSchema, couponRuleSchema, couponSchema, couponStatsSchema, couponStatusSchema, couponTargetInputSchema, couponTargetSchema, createCouponRequestSchema, createPkcePair, createStoreClient, createStoreSession, createStorefrontEditPreviewLinkRequestSchema, createStorefrontPreviewLinkRequestSchema, createStorefrontSiteRequestSchema, createStorefrontVersionRequestSchema, customInputLabelForbiddenWord, customInputRequestSchema, customInputSchema, customInputValueSchema, customerAddressSchema, customerConsentListQuerySchema, customerConsentSchema, customerConsentStateSchema, customerConsentsSchema, customerCouponSchema, customerDelegationRequestSchema, customerDelegationSchema, customerDetailSchema, customerInquiryCategorySchema, customerInquiryListQuerySchema, customerListQuerySchema, customerOrderSchema, customerPointsSchema, customerSortSchema, customerStatsSchema, customerSummarySchema, customerWithdrawalBlockedDetailsSchema, deleteStorefrontFileRequestSchema, deliveryBundleKeyOf, deliveryFeeWaiverSchema, deliveryInfoSchema, deliveryMethodSchema, deliveryStatusSchema, deliveryTypeSchema, descendantCategoryIdsOf, disableStorefrontHostingRequestSchema, discountRequestSchema, discountSchema, dispatchRequestSchema, easyPayProviderResponseSchema, easyPayProviderSchema, eventTypeSchema, exchangeAuthorizationCode, formatOrderNo, fulfillBulkRequestSchema, fulfillRequestSchema, fulfillmentRuleOf, fulfillmentTypeOf, fulfillmentTypeResponseSchema, fulfillmentTypeSchema, holdOrderItemRequestSchema, inquiryListQuerySchema, inquirySchema, inquiryWebhookEventDataSchema, inquiryWebhookEventSchema, invitationDeliveryStatusSchema, invitationListQuerySchema, invitationSchema, inviteMemberRequestSchema, isCouponTargetLine, isEditableStorefrontPath, isReservedStoreCode, isReservedStorefrontSlug, isShowcaseStorefrontSlug, isStoreScope, isWebOrigin, issueCouponRequestSchema, issueCouponResultSchema, liveGateConditionCodeSchema, liveGateConditionSchema, liveGateErrorDetailsSchema, liveGateSchema, loginProviderSchema, loginProviderStatusSchema, loginProviderTestSchema, loginSettingsSchema, maskedSecretSchema, matchesCollectionRules, mcpRuleResultSchema, mcpToolEventSchema, moveStorefrontFileRequestSchema, myAccountSchema, myStoreSchema, normalizeBusinessNumber, normalizeCouponCode, normalizeStorefrontHostname, normalizeStorefrontPath, oauthTokenResponseSchema, openFulfillmentUnion, optionGroupKindSchema, optionGroupRequestSchema, optionGroupSchema, optionModelRequestSchema, optionModelSchema, optionSelectionSchema, optionSortSchema, optionValueRequestSchema, optionValueSchema, orderCanceledWebhookEventDataSchema, orderCanceledWebhookEventSchema, orderDiscountSchema, orderFulfilledWebhookEventDataSchema, orderFulfilledWebhookEventSchema, orderItemFulfillmentSchema, orderItemFulfillmentSnapshotResponseSchema, orderItemFulfillmentSnapshotSchema, orderItemListQuerySchema, orderItemMemoResultSchema, orderItemPageSchema, orderItemSchema, orderItemStatusSchema, orderListQuerySchema, orderSchema, orderSummaryPageSchema, orderSummarySchema, orderWebhookEventDataSchema, orderWebhookEventSchema, pageInfoSchema, pageQueryShape, pageSchema, parseOrderNo, paymentAttemptRecordSchema, paymentAttemptStatusSchema, paymentCredentialSetSchema, paymentFailureWarningSchema, paymentListQuerySchema, paymentProviderSchema, paymentProviderVerificationSchema, paymentRecordDetailSchema, paymentRecordPageSchema, paymentRecordSchema, paymentRecordStatusSchema, paymentRefundRecordSchema, paymentSettingsSchema, pgEnvironmentSchema, pgPaymentMethodSchema, pgProviderSchema, pgVerificationResultSchema, planCodeSchema, planEntitlementsSchema, planErrorDetailsSchema, pointAdjustmentRequestSchema, pointAdjustmentResultSchema, pointEarnOf, pointEarnRateBpSchema, pointEarningEnabled, pointEntrySchema, pointExpiresAtOf, pointHistoryQuerySchema, pointLotSchema, pointPolicyNoticeSchema, pointPolicySchema, pointRestoreExpiresAtOf, pointUseOf, pointUsePolicySchema, policyDocumentUrlSchema, policyVersionSchema, portOneChannelSchema, portOneCredentialsInputSchema, productCreateRequestSchema, productFulfillmentCreateSchema, productFulfillmentResponseSchema, productFulfillmentSchema, productFulfillmentUpdateSchema, productImageRejection, productImageUrlSchema, productListQuerySchema, productOutOfStockWebhookEventDataSchema, productOutOfStockWebhookEventSchema, productPatchRequestSchema, productRefundPolicyOverride, productRefundPolicyPatchSchema, productReplaceRequestSchema, productSchema, productSortSchema, productStatusSchema, productSummarySchema, productVariantRequestSchema, productVariantSchema, proratedPaidRefundBase, proratedPointRefund, proratedRefundBase, publicPlanSchema, publicPlansSchema, publishStorefrontVersionRequestSchema, purchaseDecisionExtendResultSchema, purchaseDecisionRequestResultSchema, purchaseEarnPolicySchema, purchaseEarnRateOf, quoteDelivery, quotePricing, rankBestSelling, refreshUserToken, refundPolicyPatchSchema, refundPolicySchema, rejectClaimRequestSchema, remoteAreaLabelOf, remoteAreaOf, remoteAreaSchema, remoteSurchargeOf, replaceStorefrontSourceRequestSchema, requiresCollection, requiresShipping, resolvePointPolicy, resolveRefundPolicy, resolveShippingPolicy, responsePlanCodeSchema, responsePointEntryTypeSchema, reviewListQuerySchema, reviewReportResultSchema, reviewRewardPointOf, reviewRewardPolicySchema, reviewSchema, reviewSortSchema, reviewWebhookEventDataSchema, reviewWebhookEventSchema, rollbackStorefrontRequestSchema, runStorefrontCheckRequestSchema, salesReportGroupBySchema, salesReportQuerySchema, salesReportRowSchema, salesReportSchema, salesTotalsSchema, saveLoginProviderRequestSchema, savedCustomInputRequestSchema, savedCustomInputSchema, savedOptionGroupRequestSchema, savedOptionGroupSchema, savedOptionSetCompositionSchema, savedOptionSetFromProductRequestSchema, savedOptionSetFromProductResultSchema, savedOptionSetListQuerySchema, savedOptionSetRequestSchema, savedOptionSetSchema, savedOptionSetSortSchema, savedOptionValueRequestSchema, savedOptionValueSchema, scopeAccessSchema, searchStorefrontFilesRequestSchema, sellerAddressListQuerySchema, sellerAddressRequestSchema, sellerAddressSchema, sellerCustomerInquirySchema, setStorefrontVisibilityRequestSchema, settleCouponShortfall, settlementDetailQuerySchema, settlementDetailSchema, settlementListQuerySchema, settlementStatusSchema, settlementSummarySchema, settlementWithDetailsSchema, shippingAddressSchema, shippingPolicyPatchSchema, shippingPolicySchema, splitRefund, storeCodeSchema, storeMemberRoleUpdatedSchema, storeMemberSchema, storePointPolicySchema, storeRoleSchema, storeSchema, storeScopeResourceSchema, storeSubscriptionSchema, storefrontBuildDependenciesSchema, storefrontBuildListQuerySchema, storefrontBuildSchema, storefrontBuildStatusSchema, storefrontCheckSchema, storefrontCheckStatusSchema, storefrontCustomDomainStatusSchema, storefrontCustomHostnameProblem, storefrontDependencyFindingSchema, storefrontDeploymentLogSchema, storefrontDeploymentSchema, storefrontDeploymentStepSchema, storefrontDnsRecordSchema, storefrontDomainSchema, storefrontDomainTxtNameOf, storefrontEditPreviewLabelOf, storefrontEditPreviewSchema, storefrontEditSessionSchema, storefrontEditSessionStatusSchema, storefrontEditingSchema, storefrontFileConflictDetailsSchema, storefrontFileContentQuerySchema, storefrontFileContentSchema, storefrontFileDeleteResultSchema, storefrontFileEncodingSchema, storefrontFileEntrySchema, storefrontFileHashSchema, storefrontFileListQuerySchema, storefrontFileListSchema, storefrontFileMoveResultSchema, storefrontFilePathSchema, storefrontFileSearchResultSchema, storefrontFileWriteResultSchema, storefrontHostingSchema, storefrontPreviewLinkSchema, storefrontProvisioningSchema, storefrontRuleResultSchema, storefrontRuleSeveritySchema, storefrontSiteDomainSchema, storefrontSiteDomainsSchema, storefrontSiteSchema, storefrontSiteStatusSchema, storefrontSlugAvailabilityQuerySchema, storefrontSlugAvailabilitySchema, storefrontSlugSchema, storefrontSourceArchivePartSchema, storefrontSourceArchiveQuerySchema, storefrontSourceBlobsResultSchema, storefrontSourceModeSchema, storefrontSourceRefSchema, storefrontSourceReplacedSchema, storefrontSourceSchema, storefrontSuspensionSchema, storefrontTemplateSchema, storefrontVerifyReportSchema, storefrontVersionCreatedSchema, storefrontVersionSchema, storefrontVersionStatusSchema, storefrontVisibilitySchema, subscriptionLimitsSchema, subscriptionStatusSchema, subscriptionUsageSchema, tossPaymentsCredentialsInputSchema, trackingStageResponseSchema, trackingUpdateResultSchema, updateCouponRequestSchema, updateLoginProviderRequestSchema, updateLoginSettingsRequestSchema, updateMemberRoleRequestSchema, updatePaymentProviderRequestSchema, updatePaymentSettingsRequestSchema, updatePointPolicyRequestSchema, updateStoreRequestSchema, uploadExtensionOf, uploadPurposeSchema, uploadRejection, uploadRequestSchema, uploadStorefrontSourceBlobsRequestSchema, uploadTicketSchema, upsertPortOneProviderRequestSchema, upsertTossPaymentsProviderRequestSchema, variantStockRequestSchema, variantStockSchema, verifyPaymentProviderRequestSchema, webhookCreatedSchema, webhookDeliveryDetailSchema, webhookDeliveryErrorCodeSchema, webhookDeliveryListQuerySchema, webhookDeliveryResourceSchema, webhookDeliverySchema, webhookDeliveryStatusSchema, webhookEventSchema, webhookFailureReasonSchema, webhookRedeliverFailedResultSchema, webhookRequestHeaderSchema, webhookRequestSchema, webhookResourceTypeSchema, webhookSchema, webhookSecretRotatedSchema, webhookStatusSchema, webhookTestRequestSchema, webhookTestResultSchema, withdrawCustomerRequestSchema, writeDryRunResultSchema, writePreviewSchema, writeStorefrontFilesRequestSchema };
|
package/package.json
CHANGED
package/src/index.ts
CHANGED
|
@@ -23,6 +23,7 @@ export * from "./schemas/auth";
|
|
|
23
23
|
export * from "./schemas/category";
|
|
24
24
|
export * from "./schemas/claim";
|
|
25
25
|
export * from "./schemas/collection";
|
|
26
|
+
export * from "./schemas/commerce-number";
|
|
26
27
|
export * from "./schemas/common";
|
|
27
28
|
export * from "./schemas/coupon";
|
|
28
29
|
export * from "./schemas/customer";
|
package/src/schemas/claim.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
+
import { commerceNumberField } from "./commerce-number";
|
|
2
3
|
import { type PageParams, pageQueryShape } from "./common";
|
|
3
4
|
|
|
4
5
|
export const claimTypeSchema = z.enum(["CANCEL", "RETURN", "EXCHANGE"]);
|
|
@@ -50,6 +51,9 @@ export type ClaimReturnAddress = z.infer<typeof claimReturnAddressSchema>;
|
|
|
50
51
|
|
|
51
52
|
export const claimSchema = z.object({
|
|
52
53
|
claimId: z.string(),
|
|
54
|
+
claimNo: commerceNumberField(
|
|
55
|
+
"클레임번호(이슈 #107) — `C` + YYMMDD(KST) + 숫자 8자리. 취소·반품·교환 접수 단위 번호이고 생성 후 바뀌지 않습니다",
|
|
56
|
+
),
|
|
53
57
|
type: claimTypeSchema,
|
|
54
58
|
status: claimStatusSchema,
|
|
55
59
|
orderId: z.string(),
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 국내 쇼핑몰 번호 체계(이슈 #107) — 공개 ID(`ord_…` 등)와 따로 싣는 숫자 번호의 표기·필드.
|
|
5
|
+
* 번호는 서버가 만들고 생성 후 바뀌지 않는다. 새 필드라 옛 서버 응답에는 없다 — 파싱은 null로 채운다.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* 번호 표기 — 숫자를 앞에서부터 4자리씩 하이픈으로 나눈다. 주문번호 `26100284731592` → `2610-0284-7315-92`,
|
|
10
|
+
* 상품주문번호 `2610028473159201` → `2610-0284-7315-9201`. 숫자만으로 된 값이 아니면(클레임번호 `C…`) 그대로, 없으면 빈 문자열이다.
|
|
11
|
+
* 화면 표기 전용이다 — API에 보낼 때는 원래 값을 쓴다(주문번호 조회는 하이픈도 받는다)
|
|
12
|
+
*/
|
|
13
|
+
export function formatOrderNo(no: string | null | undefined): string {
|
|
14
|
+
if (!no) return "";
|
|
15
|
+
if (!/^\d+$/.test(no)) return no;
|
|
16
|
+
return no.match(/.{1,4}/g)?.join("-") ?? no;
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
/** 표기 하이픈·공백을 지운 숫자 번호. 숫자가 아닌 글자가 남거나 비면 null */
|
|
20
|
+
export function parseOrderNo(value: string): string | null {
|
|
21
|
+
const digits = value.replace(/[\s-]/g, "");
|
|
22
|
+
return /^\d+$/.test(digits) ? digits : null;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
/** 응답 번호 필드 — 서버는 항상 싣고, 번호 체계 이전 행(백필 전)·옛 서버 응답은 null이다 */
|
|
26
|
+
export function commerceNumberField(description: string) {
|
|
27
|
+
return z.string().nullable().optional().default(null).describe(description);
|
|
28
|
+
}
|
package/src/schemas/order.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
|
+
import { commerceNumberField } from "./commerce-number";
|
|
2
3
|
import { changeTypeSchema, orderItemStatusSchema, type PageParams, pageSchema } from "./common";
|
|
3
4
|
import { orderItemFulfillmentSnapshotResponseSchema } from "./fulfillment";
|
|
4
5
|
import { cashReceiptSchema, easyPayProviderResponseSchema } from "./payment";
|
|
@@ -6,6 +7,9 @@ import { customInputValueSchema, optionSelectionSchema } from "./product";
|
|
|
6
7
|
|
|
7
8
|
export const orderSummarySchema = z.object({
|
|
8
9
|
orderId: z.string(),
|
|
10
|
+
orderNo: commerceNumberField(
|
|
11
|
+
"주문번호(이슈 #107) — 숫자 14자리(YYMMDD KST + 난수 8자리), 전역 유일, 생성 후 바뀌지 않습니다. 전화 CS·ARS용 번호이고 API 경로의 식별자는 여전히 `orderId`입니다. 화면 표기는 `formatOrderNo`(4자리 하이픈)를 쓰십시오",
|
|
12
|
+
),
|
|
9
13
|
ordererName: z.string(),
|
|
10
14
|
itemCount: z.number().int(),
|
|
11
15
|
totalAmount: z.number().int(),
|
|
@@ -53,6 +57,9 @@ export type OrderItemFulfillment = z.infer<typeof orderItemFulfillmentSchema>;
|
|
|
53
57
|
|
|
54
58
|
export const orderItemSchema = z.object({
|
|
55
59
|
orderItemId: z.string(),
|
|
60
|
+
orderItemNo: commerceNumberField(
|
|
61
|
+
"상품주문번호(이슈 #107) — 주문번호 + 줄 순번 2자리(01부터, 100줄부터 3자리). 부분 취소·클레임·송장의 처리 단위 번호이고 생성 후 바뀌지 않습니다",
|
|
62
|
+
),
|
|
56
63
|
orderId: z.string(),
|
|
57
64
|
status: orderItemStatusSchema,
|
|
58
65
|
claimStatus: z.enum(["CANCEL_REQUESTED", "RETURN_REQUESTED", "EXCHANGE_REQUESTED"]).nullable(),
|
|
@@ -151,6 +158,9 @@ export type OrderDiscount = z.infer<typeof orderDiscountSchema>;
|
|
|
151
158
|
|
|
152
159
|
export const orderSchema = z.object({
|
|
153
160
|
orderId: z.string(),
|
|
161
|
+
orderNo: commerceNumberField(
|
|
162
|
+
"주문번호(이슈 #107) — 숫자 14자리(YYMMDD KST + 난수 8자리), 전역 유일, 생성 후 바뀌지 않습니다. 전화 CS·ARS용 번호이고 API 경로의 식별자는 여전히 `orderId`입니다. 화면 표기는 `formatOrderNo`(4자리 하이픈)를 쓰십시오",
|
|
163
|
+
),
|
|
154
164
|
orderedAt: z.string(),
|
|
155
165
|
orderer: z.object({
|
|
156
166
|
name: z.string(),
|
|
@@ -271,11 +281,14 @@ const pageQuery = {
|
|
|
271
281
|
|
|
272
282
|
/**
|
|
273
283
|
* `GET /v1/orders` 쿼리 — OpenAPI 문서용 형태(값은 쿼리 문자열). 검증 규칙은 서버가 적용한다:
|
|
274
|
-
* `orderedFrom` 누락 400 `MISSING_PARAMETER`,
|
|
284
|
+
* `orderNo` 없이 `orderedFrom` 누락 400 `MISSING_PARAMETER`, 날짜·`orderNo` 형식 오류 400 `INVALID_PARAMETER`, 31일 초과 400 `RANGE_TOO_WIDE`,
|
|
275
285
|
* `testPayment`가 `true`·`false`가 아니면 400 `INVALID_PARAMETER`
|
|
276
286
|
*/
|
|
277
287
|
export const orderListQuerySchema = z.object({
|
|
278
|
-
orderedFrom: z
|
|
288
|
+
orderedFrom: z
|
|
289
|
+
.string()
|
|
290
|
+
.optional()
|
|
291
|
+
.describe("조회 시작 시각 (ISO 8601 날짜 또는 일시, 포함). `orderNo`가 없으면 필수"),
|
|
279
292
|
orderedTo: z
|
|
280
293
|
.string()
|
|
281
294
|
.optional()
|
|
@@ -283,7 +296,16 @@ export const orderListQuerySchema = z.object({
|
|
|
283
296
|
status: orderItemStatusSchema
|
|
284
297
|
.optional()
|
|
285
298
|
.describe("주문상품 상태 필터 — 이 상태의 주문상품이 하나라도 있는 주문"),
|
|
286
|
-
keyword: z
|
|
299
|
+
keyword: z
|
|
300
|
+
.string()
|
|
301
|
+
.optional()
|
|
302
|
+
.describe("주문 id·주문번호(일치, 하이픈 허용)·주문자명·수령인명(포함) 검색"),
|
|
303
|
+
orderNo: z
|
|
304
|
+
.string()
|
|
305
|
+
.optional()
|
|
306
|
+
.describe(
|
|
307
|
+
"주문번호 조회(이슈 #107) — 숫자 14자리, 하이픈 허용(`2610-0284-7315-92`). 주면 기간 조건 없이 그 주문만 찾습니다. 형식이 아니면 400 `INVALID_PARAMETER`",
|
|
308
|
+
),
|
|
287
309
|
fulfillmentType: z
|
|
288
310
|
.string()
|
|
289
311
|
.optional()
|
|
@@ -314,7 +336,10 @@ export const orderItemListQuerySchema = z.object({
|
|
|
314
336
|
});
|
|
315
337
|
|
|
316
338
|
export interface OrderListParams extends PageParams {
|
|
317
|
-
|
|
339
|
+
/** 조회 시작 시각 — `orderNo`가 없으면 필수 */
|
|
340
|
+
orderedFrom?: string;
|
|
341
|
+
/** 주문번호 조회(이슈 #107) — 주면 기간 없이 그 주문만 찾는다 */
|
|
342
|
+
orderNo?: string;
|
|
318
343
|
orderedTo?: string;
|
|
319
344
|
status?: z.infer<typeof orderItemStatusSchema>;
|
|
320
345
|
keyword?: string;
|
package/src/schemas/payment.ts
CHANGED
|
@@ -624,7 +624,18 @@ export const paymentRecordSchema = z.object({
|
|
|
624
624
|
environment: pgEnvironmentSchema.nullable().describe("결제 환경"),
|
|
625
625
|
testPayment: z.boolean().describe("샌드박스 결제인가"),
|
|
626
626
|
pgTransactionId: z.string().nullable().describe("PG 거래 id (토스 paymentKey, 포트원 txId)"),
|
|
627
|
-
attemptId: z
|
|
627
|
+
attemptId: z
|
|
628
|
+
.string()
|
|
629
|
+
.nullable()
|
|
630
|
+
.describe("대표 시도 id. 번호 체계(이슈 #107) 이전 시도는 이 값을 PG 주문번호로 보냈습니다"),
|
|
631
|
+
pgOrderId: z
|
|
632
|
+
.string()
|
|
633
|
+
.nullable()
|
|
634
|
+
.optional()
|
|
635
|
+
.default(null)
|
|
636
|
+
.describe(
|
|
637
|
+
"PG에 보낸 주문번호(이슈 #107) — 토스페이먼츠 orderId·포트원 paymentId. 새 시도는 `{주문번호}-{시도 순번 2자리}`이고, 번호 체계 이전 시도는 시도 id(`attemptId`)와 같습니다. PG 관리자 화면에서 결제를 찾을 때 씁니다",
|
|
638
|
+
),
|
|
628
639
|
attemptCount: z.number().int().describe("시도 횟수"),
|
|
629
640
|
failCode: z.string().nullable().describe("실패 코드. 실패로 끝난 결제만"),
|
|
630
641
|
failMessage: z.string().nullable().describe("실패 사유"),
|
|
@@ -646,6 +657,14 @@ export type PaymentRecordPage = z.infer<typeof paymentRecordPageSchema>;
|
|
|
646
657
|
|
|
647
658
|
export const paymentAttemptRecordSchema = z.object({
|
|
648
659
|
attemptId: z.string(),
|
|
660
|
+
pgOrderId: z
|
|
661
|
+
.string()
|
|
662
|
+
.nullable()
|
|
663
|
+
.optional()
|
|
664
|
+
.default(null)
|
|
665
|
+
.describe(
|
|
666
|
+
"PG에 보낸 주문번호(이슈 #107) — 토스페이먼츠 orderId·포트원 paymentId. 새 시도는 `{주문번호}-{시도 순번 2자리}`이고, 번호 체계 이전 시도는 시도 id(`attemptId`)와 같습니다. PG 관리자 화면에서 결제를 찾을 때 씁니다",
|
|
667
|
+
),
|
|
649
668
|
sequence: z.number().int().describe("결제 건 안에서의 순번 (1부터)"),
|
|
650
669
|
provider: pgProviderSchema,
|
|
651
670
|
status: paymentAttemptStatusSchema,
|
|
@@ -721,7 +740,7 @@ export const paymentListQuerySchema = z.object({
|
|
|
721
740
|
keyword: z
|
|
722
741
|
.string()
|
|
723
742
|
.optional()
|
|
724
|
-
.describe("결제 id
|
|
743
|
+
.describe("결제 id·주문 id·PG 거래 id·시도 id·PG 주문번호(일치), 구매자명(포함)"),
|
|
725
744
|
includeTest: z
|
|
726
745
|
.string()
|
|
727
746
|
.optional()
|
package/src/schemas/product.ts
CHANGED
|
@@ -16,6 +16,15 @@ export type ProductStatus = z.infer<typeof productStatusSchema>;
|
|
|
16
16
|
|
|
17
17
|
export const productSummarySchema = z.object({
|
|
18
18
|
productId: z.string(),
|
|
19
|
+
productNo: z
|
|
20
|
+
.number()
|
|
21
|
+
.int()
|
|
22
|
+
.nullable()
|
|
23
|
+
.optional()
|
|
24
|
+
.default(null)
|
|
25
|
+
.describe(
|
|
26
|
+
"상품번호(이슈 #107) — 상점별 1부터 증가하는 숫자, 상점 안에서 유일, 생성 후 바뀌지 않으며 지운 상품의 번호는 다시 쓰지 않습니다. URL에 써도 됩니다(스토어프론트 상품 상세 경로가 받습니다). 번호 체계 이전 응답은 null",
|
|
27
|
+
),
|
|
19
28
|
name: z.string(),
|
|
20
29
|
status: productStatusSchema,
|
|
21
30
|
salePrice: z.number().int().describe("판매가. 원(KRW) 단위 정수"),
|
|
@@ -72,6 +81,14 @@ export type OptionGroup = z.infer<typeof optionGroupSchema>;
|
|
|
72
81
|
*/
|
|
73
82
|
export const productVariantSchema = z.object({
|
|
74
83
|
variantId: z.string(),
|
|
84
|
+
variantNo: z
|
|
85
|
+
.string()
|
|
86
|
+
.nullable()
|
|
87
|
+
.optional()
|
|
88
|
+
.default(null)
|
|
89
|
+
.describe(
|
|
90
|
+
"조합 번호(이슈 #107) — `{productNo}-{조합 순번 2자리}`(예: `10482-03`). 시스템이 매기는 SKU이고 상점 안에서 유일합니다(상품번호가 상점 범위라 다른 상점과는 겹칠 수 있습니다). 생성 후 바뀌지 않으며, 지운 조합의 번호는 다시 쓰지 않습니다. 셀러가 입력하는 `sku`와 별개입니다",
|
|
91
|
+
),
|
|
75
92
|
/** 축 sortOrder 순서와 1:1 대응. 옵션 없는 상품은 [] */
|
|
76
93
|
valueIds: z.array(z.string()),
|
|
77
94
|
/** 값 이름을 " / "로 이은 파생 표시명. 옵션 없으면 "" */
|
|
@@ -657,6 +674,8 @@ export interface ProductListParams extends PageParams {
|
|
|
657
674
|
categoryId?: string;
|
|
658
675
|
keyword?: string;
|
|
659
676
|
sellerCode?: string;
|
|
677
|
+
/** 상품번호(이슈 #107, 상점 범위) — 그 상품만 */
|
|
678
|
+
productNo?: number;
|
|
660
679
|
sort?: ProductSort;
|
|
661
680
|
}
|
|
662
681
|
|
|
@@ -669,6 +688,12 @@ export const productListQuerySchema = z.object({
|
|
|
669
688
|
.string()
|
|
670
689
|
.optional()
|
|
671
690
|
.describe("판매자 상품코드 — 이 코드가 붙은 variant를 가진 상품"),
|
|
691
|
+
productNo: z
|
|
692
|
+
.string()
|
|
693
|
+
.optional()
|
|
694
|
+
.describe(
|
|
695
|
+
"상품번호(이슈 #107) — 이 상점의 그 번호 상품만. 숫자가 아니면 400 `INVALID_PARAMETER`",
|
|
696
|
+
),
|
|
672
697
|
sort: productSortSchema.optional().describe("정렬 (기본 createdAt.desc)"),
|
|
673
698
|
...pageQueryShape(),
|
|
674
699
|
});
|
|
@@ -41,6 +41,14 @@ const envelopeFields = {
|
|
|
41
41
|
|
|
42
42
|
export const orderWebhookEventDataSchema = z.object({
|
|
43
43
|
orderId: z.string().describe("주문 ID"),
|
|
44
|
+
orderNo: z
|
|
45
|
+
.string()
|
|
46
|
+
.nullable()
|
|
47
|
+
.optional()
|
|
48
|
+
.default(null)
|
|
49
|
+
.describe(
|
|
50
|
+
"주문번호(이슈 #107) — 숫자 14자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 주문은 null로 읽는다",
|
|
51
|
+
),
|
|
44
52
|
status: orderItemStatusSchema.describe("이벤트 발생 시점의 주문 대표 상태"),
|
|
45
53
|
testPayment: z
|
|
46
54
|
.boolean()
|
|
@@ -101,6 +109,14 @@ export type OrderWebhookEventData = z.infer<typeof orderWebhookEventDataSchema>;
|
|
|
101
109
|
*/
|
|
102
110
|
export const orderFulfilledWebhookEventDataSchema = z.object({
|
|
103
111
|
orderId: z.string().describe("주문 ID"),
|
|
112
|
+
orderNo: z
|
|
113
|
+
.string()
|
|
114
|
+
.nullable()
|
|
115
|
+
.optional()
|
|
116
|
+
.default(null)
|
|
117
|
+
.describe(
|
|
118
|
+
"주문번호(이슈 #107) — 숫자 14자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 주문은 null로 읽는다",
|
|
119
|
+
),
|
|
104
120
|
orderItemId: z.string().describe("제공한 주문상품 ID"),
|
|
105
121
|
status: orderItemStatusSchema.describe("이벤트 발생 시점의 주문 대표 상태"),
|
|
106
122
|
fulfillmentSnapshot: orderItemFulfillmentSnapshotResponseSchema.describe(
|
|
@@ -126,6 +142,14 @@ export type OrderFulfilledWebhookEventData = z.infer<typeof orderFulfilledWebhoo
|
|
|
126
142
|
*/
|
|
127
143
|
export const orderCanceledWebhookEventDataSchema = z.object({
|
|
128
144
|
orderId: z.string().describe("주문 ID"),
|
|
145
|
+
orderNo: z
|
|
146
|
+
.string()
|
|
147
|
+
.nullable()
|
|
148
|
+
.optional()
|
|
149
|
+
.default(null)
|
|
150
|
+
.describe(
|
|
151
|
+
"주문번호(이슈 #107) — 숫자 14자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 주문은 null로 읽는다",
|
|
152
|
+
),
|
|
129
153
|
orderItemId: z.string().describe("취소한 주문 상품 ID"),
|
|
130
154
|
status: orderItemStatusSchema.describe(
|
|
131
155
|
"취소 뒤 주문 대표 상태. 모든 주문 상품이 취소됐으면 `CANCELED`다",
|
|
@@ -188,6 +212,14 @@ export type OrderCanceledWebhookEventData = z.infer<typeof orderCanceledWebhookE
|
|
|
188
212
|
|
|
189
213
|
export const claimWebhookEventDataSchema = z.object({
|
|
190
214
|
claimId: z.string().describe("클레임 ID"),
|
|
215
|
+
claimNo: z
|
|
216
|
+
.string()
|
|
217
|
+
.nullable()
|
|
218
|
+
.optional()
|
|
219
|
+
.default(null)
|
|
220
|
+
.describe(
|
|
221
|
+
"클레임번호(이슈 #107) — `C` + YYMMDD + 숫자 8자리. 이 필드가 없는 이전 이벤트와 번호 체계 이전 클레임은 null로 읽는다",
|
|
222
|
+
),
|
|
191
223
|
orderId: z.string().describe("주문 ID"),
|
|
192
224
|
orderItemId: z.string().describe("클레임 대상 주문 상품 ID"),
|
|
193
225
|
claimType: claimTypeSchema.describe("클레임 유형"),
|