@sayren/store-sdk 0.43.0 → 0.45.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 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
- DENIED: "DENIED";
169
168
  APPROVAL_REQUIRED: "APPROVAL_REQUIRED";
169
+ DENIED: "DENIED";
170
170
  ALLOW: "ALLOW";
171
171
  }>;
172
172
  export type AgentPolicyDecision = z.infer<typeof agentPolicyDecisionSchema>;
@@ -191,8 +191,8 @@ export type WritePreview = z.infer<typeof writePreviewSchema>;
191
191
  export declare const writeDryRunResultSchema: z.ZodObject<{
192
192
  dryRun: z.ZodLiteral<true>;
193
193
  decision: z.ZodEnum<{
194
- DENIED: "DENIED";
195
194
  APPROVAL_REQUIRED: "APPROVAL_REQUIRED";
195
+ DENIED: "DENIED";
196
196
  ALLOW: "ALLOW";
197
197
  }>;
198
198
  reason: z.ZodNullable<z.ZodString>;
@@ -500,9 +500,9 @@ export type AiRun = z.infer<typeof aiRunSchema>;
500
500
  */
501
501
  export declare const aiActivitySchema: z.ZodEnum<{
502
502
  code: "code";
503
+ status: "status";
503
504
  check: "check";
504
505
  version: "version";
505
- status: "status";
506
506
  shipping: "shipping";
507
507
  category: "category";
508
508
  brief: "brief";
@@ -755,9 +755,9 @@ export declare const aiMessagePartSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
755
755
  summary: z.ZodNullable<z.ZodString>;
756
756
  activity: z.ZodOptional<z.ZodEnum<{
757
757
  code: "code";
758
+ status: "status";
758
759
  check: "check";
759
760
  version: "version";
760
- status: "status";
761
761
  shipping: "shipping";
762
762
  category: "category";
763
763
  brief: "brief";
@@ -911,9 +911,9 @@ export declare const aiMessageSchema: z.ZodObject<{
911
911
  summary: z.ZodNullable<z.ZodString>;
912
912
  activity: z.ZodOptional<z.ZodEnum<{
913
913
  code: "code";
914
+ status: "status";
914
915
  check: "check";
915
916
  version: "version";
916
- status: "status";
917
917
  shipping: "shipping";
918
918
  category: "category";
919
919
  brief: "brief";
@@ -1082,9 +1082,9 @@ export declare const aiConversationSchema: z.ZodObject<{
1082
1082
  summary: z.ZodNullable<z.ZodString>;
1083
1083
  activity: z.ZodOptional<z.ZodEnum<{
1084
1084
  code: "code";
1085
+ status: "status";
1085
1086
  check: "check";
1086
1087
  version: "version";
1087
- status: "status";
1088
1088
  shipping: "shipping";
1089
1089
  category: "category";
1090
1090
  brief: "brief";
@@ -1578,9 +1578,9 @@ export declare const aiStreamEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1578
1578
  }, z.core.$strip>>;
1579
1579
  activity: z.ZodOptional<z.ZodEnum<{
1580
1580
  code: "code";
1581
+ status: "status";
1581
1582
  check: "check";
1582
1583
  version: "version";
1583
- status: "status";
1584
1584
  shipping: "shipping";
1585
1585
  category: "category";
1586
1586
  brief: "brief";
@@ -1706,9 +1706,9 @@ export declare const aiStreamEventSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
1706
1706
  summary: z.ZodNullable<z.ZodString>;
1707
1707
  activity: z.ZodOptional<z.ZodEnum<{
1708
1708
  code: "code";
1709
+ status: "status";
1709
1710
  check: "check";
1710
1711
  version: "version";
1711
- status: "status";
1712
1712
  shipping: "shipping";
1713
1713
  category: "category";
1714
1714
  brief: "brief";
@@ -1934,9 +1934,9 @@ export declare const aiStreamRecordSchema: z.ZodObject<{
1934
1934
  }, z.core.$strip>>;
1935
1935
  activity: z.ZodOptional<z.ZodEnum<{
1936
1936
  code: "code";
1937
+ status: "status";
1937
1938
  check: "check";
1938
1939
  version: "version";
1939
- status: "status";
1940
1940
  shipping: "shipping";
1941
1941
  category: "category";
1942
1942
  brief: "brief";
@@ -2062,9 +2062,9 @@ export declare const aiStreamRecordSchema: z.ZodObject<{
2062
2062
  summary: z.ZodNullable<z.ZodString>;
2063
2063
  activity: z.ZodOptional<z.ZodEnum<{
2064
2064
  code: "code";
2065
+ status: "status";
2065
2066
  check: "check";
2066
2067
  version: "version";
2067
- status: "status";
2068
2068
  shipping: "shipping";
2069
2069
  category: "category";
2070
2070
  brief: "brief";
@@ -4349,8 +4349,8 @@ export declare const appManifestSchema: z.ZodObject<{
4349
4349
  icon: z.ZodOptional<z.ZodString>;
4350
4350
  readme: z.ZodOptional<z.ZodString>;
4351
4351
  runtime: z.ZodDefault<z.ZodEnum<{
4352
- external: "external";
4353
4352
  code: "code";
4353
+ external: "external";
4354
4354
  }>>;
4355
4355
  external: z.ZodOptional<z.ZodObject<{
4356
4356
  url: z.ZodURL;
@@ -5718,6 +5718,121 @@ export declare const categoryLocalizationRequestSchema: z.ZodObject<{
5718
5718
  }, z.core.$strict>;
5719
5719
  export type CategoryLocalizationRequest = z.infer<typeof categoryLocalizationRequestSchema>;
5720
5720
  //#endregion
5721
+ //#region src/schemas/checkout.d.ts
5722
+ /**
5723
+ * 셀러 작성 주문서 (이슈 #116) — 셀러가 줄·단가·유효 기한을 정해 만들고, 구매자는 스토어프론트에서 그 주문서로 결제한다.
5724
+ * 링크(주문서 id)를 가진 사람은 누구나 결제할 수 있다. 결제가 승인되면 일반 주문과 같은 주문이 생긴다.
5725
+ */
5726
+ export declare const sellerCheckoutLineSchema: z.ZodObject<{
5727
+ productId: z.ZodString;
5728
+ optionId: z.ZodOptional<z.ZodString>;
5729
+ quantity: z.ZodNumber;
5730
+ unitPrice: z.ZodOptional<z.ZodNumber>;
5731
+ addons: z.ZodOptional<z.ZodArray<z.ZodObject<{
5732
+ groupId: z.ZodString;
5733
+ valueId: z.ZodString;
5734
+ }, z.core.$strip>>>;
5735
+ customInputs: z.ZodOptional<z.ZodArray<z.ZodObject<{
5736
+ inputId: z.ZodString;
5737
+ value: z.ZodString;
5738
+ }, z.core.$strip>>>;
5739
+ }, z.core.$strip>;
5740
+ export type SellerCheckoutLineRequest = z.infer<typeof sellerCheckoutLineSchema>;
5741
+ export declare const createSellerCheckoutRequestSchema: z.ZodObject<{
5742
+ items: z.ZodArray<z.ZodObject<{
5743
+ productId: z.ZodString;
5744
+ optionId: z.ZodOptional<z.ZodString>;
5745
+ quantity: z.ZodNumber;
5746
+ unitPrice: z.ZodOptional<z.ZodNumber>;
5747
+ addons: z.ZodOptional<z.ZodArray<z.ZodObject<{
5748
+ groupId: z.ZodString;
5749
+ valueId: z.ZodString;
5750
+ }, z.core.$strip>>>;
5751
+ customInputs: z.ZodOptional<z.ZodArray<z.ZodObject<{
5752
+ inputId: z.ZodString;
5753
+ value: z.ZodString;
5754
+ }, z.core.$strip>>>;
5755
+ }, z.core.$strip>>;
5756
+ expiresAt: z.ZodISODateTime;
5757
+ fulfillmentMethod: z.ZodOptional<z.ZodEnum<{
5758
+ CARRIER: "CARRIER";
5759
+ DIRECT: "DIRECT";
5760
+ PICKUP: "PICKUP";
5761
+ PROVIDED: "PROVIDED";
5762
+ }>>;
5763
+ pickupLocationId: z.ZodOptional<z.ZodString>;
5764
+ trackInventory: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
5765
+ couponsEnabled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
5766
+ pointsEnabled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
5767
+ }, z.core.$strip>;
5768
+ export type CreateSellerCheckoutRequest = z.input<typeof createSellerCheckoutRequestSchema>;
5769
+ export declare const sellerCheckoutSchema: z.ZodObject<{
5770
+ checkoutId: z.ZodString;
5771
+ status: z.ZodString;
5772
+ checkoutUrl: z.ZodString;
5773
+ currency: z.ZodString;
5774
+ items: z.ZodArray<z.ZodObject<{
5775
+ lineId: z.ZodString;
5776
+ productId: z.ZodString;
5777
+ productName: z.ZodString;
5778
+ optionId: z.ZodNullable<z.ZodString>;
5779
+ optionName: z.ZodNullable<z.ZodString>;
5780
+ quantity: z.ZodNumber;
5781
+ unitPrice: z.ZodNumber;
5782
+ listUnitPrice: z.ZodNumber;
5783
+ totalPrice: z.ZodNumber;
5784
+ }, z.core.$strip>>;
5785
+ amounts: z.ZodObject<{
5786
+ productAmount: z.ZodNumber;
5787
+ deliveryFee: z.ZodNumber;
5788
+ totalAmount: z.ZodNumber;
5789
+ }, z.core.$strip>;
5790
+ requiresShipping: z.ZodBoolean;
5791
+ trackInventory: z.ZodBoolean;
5792
+ couponsEnabled: z.ZodBoolean;
5793
+ pointsEnabled: z.ZodBoolean;
5794
+ orderId: z.ZodNullable<z.ZodString>;
5795
+ createdAt: z.ZodString;
5796
+ expiresAt: z.ZodString;
5797
+ }, z.core.$strip>;
5798
+ export type SellerCheckout = z.infer<typeof sellerCheckoutSchema>;
5799
+ export declare const sellerCheckoutPageSchema: z.ZodObject<{
5800
+ page: z.ZodNumber;
5801
+ size: z.ZodNumber;
5802
+ totalElements: z.ZodNumber;
5803
+ totalPages: z.ZodNumber;
5804
+ contents: z.ZodArray<z.ZodObject<{
5805
+ checkoutId: z.ZodString;
5806
+ status: z.ZodString;
5807
+ checkoutUrl: z.ZodString;
5808
+ currency: z.ZodString;
5809
+ items: z.ZodArray<z.ZodObject<{
5810
+ lineId: z.ZodString;
5811
+ productId: z.ZodString;
5812
+ productName: z.ZodString;
5813
+ optionId: z.ZodNullable<z.ZodString>;
5814
+ optionName: z.ZodNullable<z.ZodString>;
5815
+ quantity: z.ZodNumber;
5816
+ unitPrice: z.ZodNumber;
5817
+ listUnitPrice: z.ZodNumber;
5818
+ totalPrice: z.ZodNumber;
5819
+ }, z.core.$strip>>;
5820
+ amounts: z.ZodObject<{
5821
+ productAmount: z.ZodNumber;
5822
+ deliveryFee: z.ZodNumber;
5823
+ totalAmount: z.ZodNumber;
5824
+ }, z.core.$strip>;
5825
+ requiresShipping: z.ZodBoolean;
5826
+ trackInventory: z.ZodBoolean;
5827
+ couponsEnabled: z.ZodBoolean;
5828
+ pointsEnabled: z.ZodBoolean;
5829
+ orderId: z.ZodNullable<z.ZodString>;
5830
+ createdAt: z.ZodString;
5831
+ expiresAt: z.ZodString;
5832
+ }, z.core.$strip>>;
5833
+ }, z.core.$strip>;
5834
+ export type SellerCheckoutPage = z.infer<typeof sellerCheckoutPageSchema>;
5835
+ //#endregion
5721
5836
  //#region src/schemas/common.d.ts
5722
5837
  export declare const pageInfoSchema: z.ZodObject<{
5723
5838
  page: z.ZodNumber;
@@ -12043,13 +12158,13 @@ export declare const discountSchema: z.ZodObject<{
12043
12158
  }, z.core.$strip>;
12044
12159
  export type Discount = z.infer<typeof discountSchema>;
12045
12160
  export declare const productSchema: z.ZodObject<{
12046
- salePrice: z.ZodNumber;
12047
12161
  status: z.ZodEnum<{
12048
12162
  SALE: "SALE";
12049
12163
  SUSPENDED: "SUSPENDED";
12050
12164
  OUT_OF_STOCK: "OUT_OF_STOCK";
12051
12165
  CLOSED: "CLOSED";
12052
12166
  }>;
12167
+ salePrice: z.ZodNumber;
12053
12168
  name: z.ZodString;
12054
12169
  stockQuantity: z.ZodNumber;
12055
12170
  categoryId: z.ZodNullable<z.ZodString>;
@@ -15966,8 +16081,8 @@ export declare function createStoreClient(options: StoreClientOptions): {
15966
16081
  }[];
15967
16082
  }>;
15968
16083
  get: (productId: string) => Promise<{
15969
- salePrice: number;
15970
16084
  status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
16085
+ salePrice: number;
15971
16086
  name: string;
15972
16087
  stockQuantity: number;
15973
16088
  categoryId: string | null;
@@ -16115,8 +16230,8 @@ export declare function createStoreClient(options: StoreClientOptions): {
16115
16230
  createdAt?: string | undefined;
16116
16231
  }>;
16117
16232
  create: (body: ProductCreateRequestInput, idempotencyKey?: string) => Promise<{
16118
- salePrice: number;
16119
16233
  status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
16234
+ salePrice: number;
16120
16235
  name: string;
16121
16236
  stockQuantity: number;
16122
16237
  categoryId: string | null;
@@ -16264,8 +16379,8 @@ export declare function createStoreClient(options: StoreClientOptions): {
16264
16379
  createdAt?: string | undefined;
16265
16380
  }>;
16266
16381
  update: (productId: string, body: ProductReplaceRequestInput) => Promise<{
16267
- salePrice: number;
16268
16382
  status: "SALE" | "SUSPENDED" | "OUT_OF_STOCK" | "CLOSED";
16383
+ salePrice: number;
16269
16384
  name: string;
16270
16385
  stockQuantity: number;
16271
16386
  categoryId: string | null;
@@ -23121,6 +23236,138 @@ export declare function createStoreClient(options: StoreClientOptions): {
23121
23236
  }>;
23122
23237
  remove: (locationId: string) => Promise<void>;
23123
23238
  };
23239
+ /**
23240
+ * 셀러 작성 주문서 (이슈 #116) — 셀러가 줄·단가·유효 기한을 정해 만들고 `checkoutId`를 결제 링크로 보낸다.
23241
+ * 구매자는 스토어프론트에서 그 주문서로 결제한다(storefront-sdk `checkout.get`). 스코프 `order:r`·`order:rw`.
23242
+ */
23243
+ checkouts: {
23244
+ create: (body: CreateSellerCheckoutRequest) => Promise<{
23245
+ checkoutId: string;
23246
+ status: string;
23247
+ checkoutUrl: string;
23248
+ currency: string;
23249
+ items: {
23250
+ lineId: string;
23251
+ productId: string;
23252
+ productName: string;
23253
+ optionId: string | null;
23254
+ optionName: string | null;
23255
+ quantity: number;
23256
+ unitPrice: number;
23257
+ listUnitPrice: number;
23258
+ totalPrice: number;
23259
+ }[];
23260
+ amounts: {
23261
+ productAmount: number;
23262
+ deliveryFee: number;
23263
+ totalAmount: number;
23264
+ };
23265
+ requiresShipping: boolean;
23266
+ trackInventory: boolean;
23267
+ couponsEnabled: boolean;
23268
+ pointsEnabled: boolean;
23269
+ orderId: string | null;
23270
+ createdAt: string;
23271
+ expiresAt: string;
23272
+ }>;
23273
+ list: (query?: {
23274
+ page?: number;
23275
+ size?: number;
23276
+ }) => Promise<{
23277
+ page: number;
23278
+ size: number;
23279
+ totalElements: number;
23280
+ totalPages: number;
23281
+ contents: {
23282
+ checkoutId: string;
23283
+ status: string;
23284
+ checkoutUrl: string;
23285
+ currency: string;
23286
+ items: {
23287
+ lineId: string;
23288
+ productId: string;
23289
+ productName: string;
23290
+ optionId: string | null;
23291
+ optionName: string | null;
23292
+ quantity: number;
23293
+ unitPrice: number;
23294
+ listUnitPrice: number;
23295
+ totalPrice: number;
23296
+ }[];
23297
+ amounts: {
23298
+ productAmount: number;
23299
+ deliveryFee: number;
23300
+ totalAmount: number;
23301
+ };
23302
+ requiresShipping: boolean;
23303
+ trackInventory: boolean;
23304
+ couponsEnabled: boolean;
23305
+ pointsEnabled: boolean;
23306
+ orderId: string | null;
23307
+ createdAt: string;
23308
+ expiresAt: string;
23309
+ }[];
23310
+ }>;
23311
+ get: (checkoutId: string) => Promise<{
23312
+ checkoutId: string;
23313
+ status: string;
23314
+ checkoutUrl: string;
23315
+ currency: string;
23316
+ items: {
23317
+ lineId: string;
23318
+ productId: string;
23319
+ productName: string;
23320
+ optionId: string | null;
23321
+ optionName: string | null;
23322
+ quantity: number;
23323
+ unitPrice: number;
23324
+ listUnitPrice: number;
23325
+ totalPrice: number;
23326
+ }[];
23327
+ amounts: {
23328
+ productAmount: number;
23329
+ deliveryFee: number;
23330
+ totalAmount: number;
23331
+ };
23332
+ requiresShipping: boolean;
23333
+ trackInventory: boolean;
23334
+ couponsEnabled: boolean;
23335
+ pointsEnabled: boolean;
23336
+ orderId: string | null;
23337
+ createdAt: string;
23338
+ expiresAt: string;
23339
+ }>;
23340
+ /** `POST /v1/checkouts/{checkoutId}/expire` — 결제 대기 중인 주문서를 바로 만료시킨다 */
23341
+ expire: (checkoutId: string) => Promise<{
23342
+ checkoutId: string;
23343
+ status: string;
23344
+ checkoutUrl: string;
23345
+ currency: string;
23346
+ items: {
23347
+ lineId: string;
23348
+ productId: string;
23349
+ productName: string;
23350
+ optionId: string | null;
23351
+ optionName: string | null;
23352
+ quantity: number;
23353
+ unitPrice: number;
23354
+ listUnitPrice: number;
23355
+ totalPrice: number;
23356
+ }[];
23357
+ amounts: {
23358
+ productAmount: number;
23359
+ deliveryFee: number;
23360
+ totalAmount: number;
23361
+ };
23362
+ requiresShipping: boolean;
23363
+ trackInventory: boolean;
23364
+ couponsEnabled: boolean;
23365
+ pointsEnabled: boolean;
23366
+ orderId: string | null;
23367
+ createdAt: string;
23368
+ expiresAt: string;
23369
+ }>;
23370
+ };
23124
23371
  /**
23125
23372
  * 상점 플랫폼 AI 채팅 (이슈 #124) — 상점 플랫폼 전용(공개 문서 제외). 메시지는 202로 `streamId`를 돌려주고
23126
23373
  * 응답은 `streamUrl`(SSE, Bearer `streamToken`)로 받는다. 실행은 브라우저와 무관하게 서버에서 끝까지 돈다.
@@ -23167,7 +23414,7 @@ export declare function createStoreClient(options: StoreClientOptions): {
23167
23414
  label: string;
23168
23415
  status: "unknown" | "error" | "ok";
23169
23416
  summary: string | null;
23170
- activity?: "code" | "check" | "version" | "status" | "shipping" | "category" | "brief" | "files" | "preview" | "template" | "site" | "info" | "upload" | "design" | "product" | "verify" | undefined;
23417
+ activity?: "code" | "status" | "check" | "version" | "shipping" | "category" | "brief" | "files" | "preview" | "template" | "site" | "info" | "upload" | "design" | "product" | "verify" | undefined;
23171
23418
  target?: string | undefined;
23172
23419
  changes?: {
23173
23420
  path: string;
@@ -26640,10 +26887,10 @@ export declare const storeIndustrySchema: z.ZodEnum<{
26640
26887
  export type StoreIndustry = z.infer<typeof storeIndustrySchema>;
26641
26888
  /** 상품 자료 — 인터뷰의 「상품 자료」 답. 상품 등록 단계의 방법을 고른다 */
26642
26889
  export declare const brandBriefProductSourceSchema: z.ZodEnum<{
26643
- NONE: "NONE";
26644
26890
  SPREADSHEET: "SPREADSHEET";
26645
26891
  EXISTING_STORE: "EXISTING_STORE";
26646
26892
  PHOTOS: "PHOTOS";
26893
+ NONE: "NONE";
26647
26894
  }>;
26648
26895
  export type BrandBriefProductSource = z.infer<typeof brandBriefProductSourceSchema>;
26649
26896
  export declare const BRAND_BRIEF_MAX_REFERENCES = 5;
@@ -26668,10 +26915,10 @@ export declare const brandBriefSchema: z.ZodObject<{
26668
26915
  summary: z.ZodString;
26669
26916
  }, z.core.$strip>>;
26670
26917
  productSource: z.ZodNullable<z.ZodEnum<{
26671
- NONE: "NONE";
26672
26918
  SPREADSHEET: "SPREADSHEET";
26673
26919
  EXISTING_STORE: "EXISTING_STORE";
26674
26920
  PHOTOS: "PHOTOS";
26921
+ NONE: "NONE";
26675
26922
  }>>;
26676
26923
  notes: z.ZodNullable<z.ZodString>;
26677
26924
  }, z.core.$strip>;
@@ -26691,10 +26938,10 @@ export declare const putBrandBriefRequestSchema: z.ZodObject<{
26691
26938
  summary: z.ZodString;
26692
26939
  }, z.core.$strip>>>;
26693
26940
  productSource: z.ZodDefault<z.ZodNullable<z.ZodEnum<{
26694
- NONE: "NONE";
26695
26941
  SPREADSHEET: "SPREADSHEET";
26696
26942
  EXISTING_STORE: "EXISTING_STORE";
26697
26943
  PHOTOS: "PHOTOS";
26944
+ NONE: "NONE";
26698
26945
  }>>>;
26699
26946
  notes: z.ZodDefault<z.ZodNullable<z.ZodString>>;
26700
26947
  }, z.core.$strip>;
@@ -26715,10 +26962,10 @@ export declare const brandBriefViewSchema: z.ZodObject<{
26715
26962
  summary: z.ZodString;
26716
26963
  }, z.core.$strip>>;
26717
26964
  productSource: z.ZodNullable<z.ZodEnum<{
26718
- NONE: "NONE";
26719
26965
  SPREADSHEET: "SPREADSHEET";
26720
26966
  EXISTING_STORE: "EXISTING_STORE";
26721
26967
  PHOTOS: "PHOTOS";
26968
+ NONE: "NONE";
26722
26969
  }>>;
26723
26970
  notes: z.ZodNullable<z.ZodString>;
26724
26971
  }, z.core.$strip>>;
package/dist/index.mjs CHANGED
@@ -6538,6 +6538,70 @@ const categoryLocalizationRequestSchema = z.strictObject({
6538
6538
  metaKeywords: z.string().max(200).nullable().optional()
6539
6539
  });
6540
6540
  //#endregion
6541
+ //#region src/schemas/checkout.ts
6542
+ /**
6543
+ * 셀러 작성 주문서 (이슈 #116) — 셀러가 줄·단가·유효 기한을 정해 만들고, 구매자는 스토어프론트에서 그 주문서로 결제한다.
6544
+ * 링크(주문서 id)를 가진 사람은 누구나 결제할 수 있다. 결제가 승인되면 일반 주문과 같은 주문이 생긴다.
6545
+ */
6546
+ const sellerCheckoutLineSchema = z.object({
6547
+ productId: z.string(),
6548
+ optionId: z.string().optional().describe("조합 id(`variants[].variantId`). 옵션 없는 상품은 생략"),
6549
+ quantity: z.number().int().min(1).max(9999),
6550
+ unitPrice: z.number().int().min(0).optional().describe("이 줄의 단가(통화 최소 단위). 생략하면 상품의 현재 판매가(즉시할인·조합 추가금·추가 선택 추가금 반영)다. 주면 그 금액이 단가가 되고, 정가보다 낮으면 차액이 주문의 할인으로 남는다"),
6551
+ addons: z.array(z.object({
6552
+ groupId: z.string(),
6553
+ valueId: z.string()
6554
+ })).max(20).optional().describe("고른 추가 선택(옵션명마다 하나). 스토어프론트 바로 구매와 같은 규칙이다"),
6555
+ customInputs: z.array(z.object({
6556
+ inputId: z.string(),
6557
+ value: z.string().max(1e3)
6558
+ })).max(20).optional().describe("직접 입력값. 스토어프론트 바로 구매와 같은 규칙이다")
6559
+ });
6560
+ const createSellerCheckoutRequestSchema = strictRequest(z.object({
6561
+ items: z.array(sellerCheckoutLineSchema).min(1).max(50),
6562
+ expiresAt: z.iso.datetime({ offset: true }).describe("유효 기한(ISO 8601). 지금 이후여야 하고, 지나면 결제할 수 없다"),
6563
+ fulfillmentMethod: z.enum([
6564
+ "CARRIER",
6565
+ "DIRECT",
6566
+ "PICKUP",
6567
+ "PROVIDED"
6568
+ ]).optional().describe("이행 방식. 스토어프론트 주문서 생성과 같은 규칙이다. 생략하면 줄마다 상품 허용 방식의 첫 값이다"),
6569
+ pickupLocationId: z.string().optional().describe("방문 수령 장소. 스토어프론트 주문서 생성과 같은 규칙이다"),
6570
+ trackInventory: z.boolean().optional().default(true).describe("재고 추적. false면 주문서를 만들 때·결제할 때 재고를 보지 않고 빼지 않는다. 그 주문의 취소·반품도 재고를 돌려주지 않는다. 기본 true"),
6571
+ couponsEnabled: z.boolean().optional().default(false).describe("구매자가 이 주문서에 쿠폰을 쓸 수 있는가. 기본 false"),
6572
+ pointsEnabled: z.boolean().optional().default(false).describe("구매자가 이 주문서에 적립금을 쓸 수 있는가. 기본 false")
6573
+ }));
6574
+ const sellerCheckoutSchema = z.object({
6575
+ checkoutId: z.string().describe("주문서 id. 결제 링크(`checkoutUrl`)나 스토어프론트가 이 id로 주문서를 열어 결제한다(`GET /storefront/v1/checkout/{checkoutId}`). 추측할 수 없는 값이고, 가진 사람은 누구나 결제할 수 있다"),
6576
+ status: z.string().describe("`OPEN`(결제 대기) · `PAID`(결제 완료) · `EXPIRED`(만료). 값이 추가될 수 있어 문자열로 받는다"),
6577
+ checkoutUrl: z.string().describe("결제 링크 — sayren이 호스팅하는 결제 페이지(`https://checkout.sayren.io/{상점 코드}/{checkoutId}`)다. 스토어프론트가 없거나 이 화면을 구현하지 않은 상점도 이 링크로 결제받는다"),
6578
+ currency: z.string(),
6579
+ items: z.array(z.object({
6580
+ lineId: z.string(),
6581
+ productId: z.string(),
6582
+ productName: z.string(),
6583
+ optionId: z.string().nullable(),
6584
+ optionName: z.string().nullable(),
6585
+ quantity: z.number().int(),
6586
+ unitPrice: z.number().int(),
6587
+ listUnitPrice: z.number().int().describe("할인 전 단가. `unitPrice`보다 크면 차액이 할인이다"),
6588
+ totalPrice: z.number().int()
6589
+ })),
6590
+ amounts: z.object({
6591
+ productAmount: z.number().int(),
6592
+ deliveryFee: z.number().int().describe("배송지를 모르는 시점의 배송비. 제주·도서산간 추가 배송비는 결제할 때 더해진다"),
6593
+ totalAmount: z.number().int()
6594
+ }),
6595
+ requiresShipping: z.boolean().describe("배송할 줄이 있는지. false면 배송지 없이 결제하고 배송비도 없다(배송 없는 상품만 담긴 주문서)"),
6596
+ trackInventory: z.boolean(),
6597
+ couponsEnabled: z.boolean(),
6598
+ pointsEnabled: z.boolean(),
6599
+ orderId: z.string().nullable().describe("결제로 만들어진 주문. 결제 전이면 null"),
6600
+ createdAt: z.string(),
6601
+ expiresAt: z.string()
6602
+ });
6603
+ const sellerCheckoutPageSchema = pageSchema(sellerCheckoutSchema);
6604
+ //#endregion
6541
6605
  //#region src/schemas/collection.ts
6542
6606
  /**
6543
6607
  * 컬렉션 (이슈 #83) — 상품을 어디에 보여 줄지 정하는 묶음이다. 카테고리는 상품이 무엇인지를 정하고 상품당 하나지만, 컬렉션은
@@ -10882,6 +10946,17 @@ list: (params) => storeHttp.request("GET", "/audit-logs", auditLogPageSchema, {
10882
10946
  remove: (locationId) => storeHttp.requestVoid("DELETE", path`/pickup-locations/${locationId}`)
10883
10947
  },
10884
10948
  /**
10949
+ * 셀러 작성 주문서 (이슈 #116) — 셀러가 줄·단가·유효 기한을 정해 만들고 `checkoutId`를 결제 링크로 보낸다.
10950
+ * 구매자는 스토어프론트에서 그 주문서로 결제한다(storefront-sdk `checkout.get`). 스코프 `order:r`·`order:rw`.
10951
+ */
10952
+ checkouts: {
10953
+ create: (body) => storeHttp.request("POST", "/checkouts", sellerCheckoutSchema, { body: createSellerCheckoutRequestSchema.parse(body) }),
10954
+ list: (query = {}) => storeHttp.request("GET", "/checkouts", sellerCheckoutPageSchema, { query }),
10955
+ get: (checkoutId) => storeHttp.request("GET", path`/checkouts/${checkoutId}`, sellerCheckoutSchema),
10956
+ /** `POST /v1/checkouts/{checkoutId}/expire` — 결제 대기 중인 주문서를 바로 만료시킨다 */
10957
+ expire: (checkoutId) => storeHttp.request("POST", path`/checkouts/${checkoutId}/expire`, sellerCheckoutSchema)
10958
+ },
10959
+ /**
10885
10960
  * 상점 플랫폼 AI 채팅 (이슈 #124) — 상점 플랫폼 전용(공개 문서 제외). 메시지는 202로 `streamId`를 돌려주고
10886
10961
  * 응답은 `streamUrl`(SSE, Bearer `streamToken`)로 받는다. 실행은 브라우저와 무관하게 서버에서 끝까지 돈다.
10887
10962
  */
@@ -11419,4 +11494,4 @@ function createStoreSession(options) {
11419
11494
  };
11420
11495
  }
11421
11496
  //#endregion
11422
- export { AI_AGENT_NOTES_DIR, AI_AGENT_PHASES, AI_DESIGN_BOARDS_MAX, AI_DESIGN_BOARD_FILE_PATTERN, AI_DESIGN_BOARD_KINDS, AI_DESIGN_CANVAS_PATH, AI_DESIGN_CONFIRM_APPROVE, AI_DESIGN_DIR, AI_DESIGN_GUIDE_PATH, AI_DESIGN_VIEWPORTS, AI_MESSAGE_MAX_ATTACHMENTS, AI_MESSAGE_MAX_CHARS, AI_RUN_ACTIVE_STATUSES, AI_RUN_FILE_CHANGES_RETENTION_DAYS, AI_RUN_RESUME_CHOICE, AI_SETUP_CONFIRM_APPROVE, AI_SITEMAP_PATH, AI_TODOS_MAX, AI_TODO_STATUSES, AI_TOOL_CHANGE_LINE_MAX, AI_TOOL_CHANGE_RANGES_MAX, APPROVAL_ALREADY_DECIDED_CODE, APPROVAL_REQUIRED_CODE, APP_CAPABILITIES, APP_DEPLOY_KEY_PATTERN, APP_DEPLOY_KEY_PREFIX, APP_EVENTS_MAX, APP_EVENT_SCOPES, APP_EVENT_TYPES, APP_FLOW_EVENT_PATTERN, APP_FLOW_ITEMS_MAX, APP_FLOW_NOTIFICATION_PATTERN, APP_HANDLE_PATTERN, APP_HTTP_KEY_PATTERN, APP_ICON_CONTENT_TYPES, APP_ICON_MAX_BYTES, APP_ICON_MIN_PX, APP_LIFECYCLE_EVENT_TYPES, APP_NETWORK_DENIED_SUFFIXES, APP_NETWORK_HOSTS_MAX, APP_PUBLIC_HTTP_MAX, APP_README_MAX_BYTES, APP_RESERVED_HANDLES, APP_SCHEDULES_MAX, APP_SCHEDULE_INTERVALS, APP_SCHEDULE_NAME_PATTERN, APP_SECRETS_MAX, APP_SECRET_NAME_PATTERN, APP_SECRET_PATTERNS, APP_SERVER_BUNDLE_MAX_GZIP_BYTES, APP_SETTINGS_MAX_FIELDS, APP_SETTING_FIELD_TYPES, APP_SETTING_KEY_PATTERN, APP_STORAGE_KEY_PATTERN, APP_STORAGE_MAX_BYTES, APP_STORAGE_MAX_KEYS, APP_TOOL_NAME_PATTERN, APP_UI_MAX_BYTES, APP_UI_MAX_FILES, ApiError, ApprovalPendingError, BASE_CURRENCY, BRAND_BRIEF_MAX_REFERENCES, BUSINESS_INFO_MAX_LENGTH, BUSINESS_NUMBER_PATTERN, CASH_RECEIPT_STATUS_VALUES, CERTIFICATION_STATUSES, 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, CURRENCIES, CURRENCY_CODES, CUSTOM_INPUT_FORBIDDEN_WORDS, CUSTOM_INPUT_TYPES, DEDICATED_EASY_PAY_PROVIDER, DEFAULT_STORE_LOCALE, FULFILLMENT_METHODS, FULFILLMENT_METHODS_BY_TYPE, FULFILLMENT_METHOD_RULES, FULFILLMENT_RULES, INSTALLABLE_SCOPES, InvalidPriceUnitError, KAKAOPAY_TEST_CID, KNOWN_WEBHOOK_EVENT_TYPES, KRW_MONEY_RULES, MAX_ADDON_GROUPS, MAX_ANALYTICS_ALLOWED_ORIGINS, MAX_AUTO_TRANSITION_DAYS, MAX_CALENDAR_DAYS, MAX_CERTIFICATION_ITEMS, 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_INFO_SECTION_TITLE, MAX_INVENTORY_OPERATION_LINES, MAX_NOTICE_VALUE_LENGTH, MAX_OPTION_GROUPS, MAX_PICKUP_LOCATIONS, MAX_PRODUCT_IMAGES, MAX_PRODUCT_INFO_SECTIONS, MAX_SAVED_OPTION_SETS, MAX_SAVED_OPTION_SET_NAME, MAX_STAY_NIGHTS, MAX_VALUES_PER_GROUP, MAX_VARIANTS, MCP_TELEMETRY_MAX_RESULTS, MIN_PAYMENT_AMOUNT, NON_INSTALLABLE_SCOPES, NO_COUPON_SETTLEMENT, NO_SHIPPING_BUNDLE_KEY, PAYMENT_ROUTING_EXCLUSION_CODES, PAYPAL_CURRENCIES, PLATFORM_CODE_SETS, 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, SAYREN_API_BASE_URL, SAYREN_API_ORIGIN, SCOPE_DESCRIPTIONS, SHIPPING_POLICY_DEFAULTS, STARTER_SELLER_TASKS, STARTER_STAGES, STOREFRONT_BLOCKED_PATH_SEGMENTS, STOREFRONT_BUILD_STAGES, STOREFRONT_BUILD_TERMINAL_STATUSES, STOREFRONT_CHECK_TERMINAL_STATUSES, STOREFRONT_CLOSED_SITE_HOLD_DAYS, 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_DRAFT_ATTACHMENT_MAX_BYTES, STORE_DRAFT_MAX_ATTACHMENTS, STORE_DRAFT_RETENTION_DAYS, STORE_ROLE_SCOPES, STORE_SCOPE_RESOURCES, STORE_SESSION_KEYS, STORE_SHOP_TYPES, TEMPLATE_STORE_LOCKED_BUSINESS_FIELDS, 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, additionalCurrencyPriceSchema, additionalCurrencyPricesSchema, addonGroupRequestSchema, addonGroupSchema, addonValueRequestSchema, addonValueSchema, addressChangeRequestListSchema, addressTypeSchema, agentPolicyDecisionSchema, aiActivitySchema, aiAgentPhaseSchema, aiAttachmentSchema, aiChoiceOptionSchema, aiConversationFileChangesSchema, aiConversationSchema, aiConversationSummarySchema, aiDesignBoardSchema, aiDesignCanvasSchema, aiDesignConfirmBoardSchema, aiDesignSelectionSchema, aiFileChangeKindSchema, aiFocusAreaSchema, aiFocusSchema, aiMessagePartSchema, aiMessageSchema, aiPreviewSelectionSchema, aiRunChangesSchema, aiRunChangesStatusSchema, aiRunFileDiffSchema, aiRunRevertConflictDetailsSchema, aiRunRevertResultSchema, aiRunSchema, aiRunStatusSchema, aiSetupConfirmItemSchema, aiStreamAccessSchema, aiStreamEventSchema, aiStreamRecordSchema, aiTodoSchema, aiToolChangeSchema, 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, appArtifactUploadSchema, appBuildSchema, appBuildStageSchema, appCapabilitiesOf, appDeployKeyCreateSchema, appDeployKeyCreatedSchema, appDeployKeySchema, appDevTokenSchema, appDistributionSchema, appEventTypeSchema, appFlowEventSchema, appFlowEventSummarySchema, appFlowNotificationSchema, appFlowNotificationSummarySchema, appFlowParamSchema, appFlowSummaryOf, appHandleSchema, appHttpKeyMatches, appIconProblem, appInstallRequestSchema, appInstallationActivitySchema, appInstallationAppSchema, appInstallationRunSchema, appInstallationSchema, appInstallationSelfSchema, appInstallationSettingsSchema, appInstallationSettingsUpdateSchema, appInstallationStatusSchema, appInvocationSchema, appListingReviewSchema, appListingReviewStatusSchema, appListingSchema, appManifestProblems, appManifestSchema, appManifestWidens, appNetworkHostProblem, appNetworkHostSchema, appReleaseResultSchema, appRuntimeSchema, appScheduleIntervalLabel, appScheduleListOf, appScheduleSummarySchema, appScopeSchema, appSecretSummarySchema, appSessionSchema, appSettingFieldSchema, appStatusSchema, appStorageEntrySchema, appStorageKeysSchema, appStorageListQuerySchema, appStoragePutSchema, appToolCallSchema, appToolInputSchema, appToolListOf, appToolResultSchema, appToolSchema, appToolSummarySchema, appVersionSchema, appVersionStatusSchema, appVisibilitySchema, applyFlowOperationsRequestSchema, approvalDecisionRequestSchema, approvalListQuerySchema, approvalPageSchema, approvalRequestSchema, approvalStatusSchema, approveClaimResultSchema, assertSaleUnit, auditActorSchema, auditActorTypeSchema, auditLogListQuerySchema, auditLogOutcomeSchema, auditLogPageSchema, auditLogSchema, auditLogSourceSchema, bestSellingRuleOf, brandBriefProductSourceSchema, brandBriefReferenceSchema, brandBriefSchema, brandBriefViewSchema, buildAuthorizeUrl, buildQuery, bulkResultSchema, businessInfoPatchShape, businessInfoResponseShape, businessNumberSchema, calendarDateSchema, calendarDaySchema, calendarQuerySchema, cancelBySellerRequestSchema, cancelBySellerResultSchema, carrierSchema, cashReceiptSchema, categoryAttributeSchema, categoryCreateRequestSchema, categoryDeleteQuerySchema, categoryDeleteStrategySchema, categoryListQuerySchema, categoryLocalizationRequestSchema, categoryLocalizationSchema, categoryPatchRequestSchema, categoryProductSortSchema, categorySchema, categorySearchResultSchema, categoryTreeNodeSchema, categoryWithPathSchema, changeStorefrontSlugRequestSchema, changeStorefrontTemplateRequestSchema, changeTypeSchema, claimCollectCompleteRequestSchema, claimDetailSchema, claimFlowEditSessionRequestSchema, claimHoldResultSchema, claimListQuerySchema, claimReasonSchema, claimRedeliveryRequestSchema, claimReturnAddressSchema, claimSchema, claimStatusSchema, claimTypeSchema, claimWebhookEventDataSchema, claimWebhookEventSchema, collectionCreateRequestSchema, collectionListQuerySchema, collectionLocalizationRequestSchema, collectionLocalizationSchema, collectionPageSchema, collectionPatchRequestSchema, collectionPreviewRequestSchema, collectionPreviewSchema, collectionProductListQuerySchema, collectionProductSchema, collectionProductSortRequestSchema, collectionProductsAddRequestSchema, collectionProductsReplaceRequestSchema, collectionRuleCategoryIds, collectionRuleSchema, collectionRuleViewSchema, collectionRulesPredicate, collectionRulesSchema, collectionSchema, collectionStateCountsSchema, collectionStateOf, collectionStateSchema, commerceFlowCheckSchema, commerceFlowSchema, commerceFlowSummarySchema, commerceFlowVersionViewSchema, commerceNumberField, compareBySales, connectStorefrontGitRequestSchema, consentActionSchema, consentKindSchema, consentSourceSchema, couponBenefitSchema, couponConditionsInputSchema, couponConditionsSchema, couponDiscountOf, couponIssueListQuerySchema, couponIssueMethodSchema, couponIssueSchema, couponIssueStatusSchema, couponKindSchema, couponListQuerySchema, couponRedemptionListQuerySchema, couponRedemptionSchema, couponRejectReasonSchema, couponRuleSchema, couponSchema, couponStatsSchema, couponStatusSchema, couponTargetInputSchema, couponTargetSchema, createAiConversationRequestSchema, createAiConversationResponseSchema, createCommerceFlowRequestSchema, createCouponRequestSchema, createMarketRequestSchema, createPkcePair, createStoreClient, createStoreDraftRequestSchema, createStoreDraftResponseSchema, createStoreSession, createStorefrontEditPreviewLinkRequestSchema, createStorefrontPreviewLinkRequestSchema, createStorefrontSiteRequestSchema, createStorefrontVersionRequestSchema, currencyCodeSchema, currencyRefundFeesSchema, currencyShippingPolicySchema, currencySpecOf, customInputLabelForbiddenWord, customInputRequestSchema, customInputSchema, customInputValueSchema, customerAddressSchema, customerConsentListQuerySchema, customerConsentSchema, customerConsentStateSchema, customerConsentsSchema, customerCouponSchema, customerDelegationRequestSchema, customerDelegationSchema, customerDetailSchema, customerInquiryCategorySchema, customerInquiryListQuerySchema, customerListQuerySchema, customerOrderSchema, customerPointsSchema, customerSortSchema, customerStatsSchema, customerSummarySchema, customerWithdrawalBlockedDetailsSchema, defaultFulfillmentMethodOf, deleteStorefrontFileRequestSchema, deliveryBundleKeyOf, deliveryFeeWaiverSchema, deliveryInfoSchema, deliveryMethodSchema, deliveryStatusSchema, deliveryTypeSchema, descendantCategoryIdsOf, describeScope, devStoreSchema, developerAppCreateSchema, developerAppSchema, developerInstallationSchema, developerOrgSchema, developerStoreSchema, disableStorefrontHostingRequestSchema, discountRequestSchema, discountSchema, dispatchRequestSchema, easyPayProviderResponseSchema, easyPayProviderSchema, eventTypeSchema, exchangeAuthorizationCode, floorToSaleUnit, flowActionRequestSchema, flowActionResultSchema, flowActionSchema, flowAuthoringGuideSchema, flowDraftEdgesSchema, flowDraftNodeSchema, flowDraftNodesSchema, flowDraftOperationSchema, flowEditSessionViewSchema, flowFieldValueSchema, flowInputFieldSchema, flowIssueSchema, flowNodeIdSchema, flowNodeTypeDetailSchema, flowNodeTypesSchema, flowNotificationWebhookEventDataSchema, flowNotificationWebhookEventSchema, flowOperationsResultSchema, flowPresetDetailSchema, flowPresetSummarySchema, flowRunSchema, flowRunStepSchema, flowSecretNameSchema, flowSecretSchema, flowStateChangedWebhookEventDataSchema, flowStateChangedWebhookEventSchema, flowStateSchema, formatOrderNo, fromDecimalString, fulfillBulkRequestSchema, fulfillRequestSchema, fulfillmentMethodOf, fulfillmentMethodSchema, fulfillmentMethodsOf, fulfillmentRuleOf, fulfillmentTypeOf, fulfillmentTypeResponseSchema, fulfillmentTypeSchema, holdOrderItemRequestSchema, infoFieldSourceSchema, infoSchemaFieldSchema, infoSchemaSchema, infoSectionLocalizationRequestSchema, infoSectionLocalizationSchema, infoSectionRequestSchema, infoSectionSchema, inquiryListQuerySchema, inquirySchema, inquiryWebhookEventDataSchema, inquiryWebhookEventSchema, inventoryAdjustmentLineSchema, inventoryAdjustmentReasonSchema, inventoryAdjustmentRequestSchema, inventoryChangedWebhookEventDataSchema, inventoryChangedWebhookEventSchema, inventoryLevelListQuerySchema, inventoryLevelPageSchema, inventoryLevelSchema, inventoryLocationRequestSchema, inventoryLocationSchema, inventoryModeSchema, inventoryMovementKindSchema, inventoryMovementListQuerySchema, inventoryMovementPageSchema, inventoryMovementSchema, inventoryOperationResultSchema, inventoryTransferRequestSchema, invitationDeliveryStatusSchema, invitationListQuerySchema, invitationSchema, inviteMemberRequestSchema, isAiAgentNotesPath, isAiChoiceAnswer, isAiDesignPath, isAiWorkspaceDocPath, isCouponTargetLine, isCurrencyCode, isEditableStorefrontPath, isInstallableScope, isReservedStoreCode, isReservedStorefrontSlug, isSaleUnitPrice, isShowcaseStorefrontSlug, isStoreScope, isWebOrigin, issueCouponRequestSchema, issueCouponResultSchema, kakaoPayCredentialsInputSchema, linkStorefrontGitInstallationRequestSchema, liveGateConditionCodeSchema, liveGateConditionSchema, liveGateErrorDetailsSchema, liveGateSchema, localeCodeSchema, loginProviderSchema, loginProviderStatusSchema, loginProviderTestSchema, loginSettingsSchema, marketSchema, maskedSecretSchema, matchesCollectionRules, mcpRuleResultSchema, mcpToolEventSchema, migrateFlowVersionRequestSchema, migrateFlowVersionResultSchema, minPaymentOf, minorToMajor, moneyRulesOf, moveFlowStateRequestSchema, moveStorefrontFileRequestSchema, myAccountSchema, myStoreSchema, naverPayCredentialsInputSchema, nightsOf, normalizeBusinessNumber, normalizeCouponCode, normalizeLocale, normalizeStorefrontHostname, normalizeStorefrontPath, oauthTokenResponseSchema, openFulfillmentUnion, optionGroupKindSchema, optionGroupRequestSchema, optionGroupSchema, optionModelRequestSchema, optionModelSchema, optionSelectionSchema, optionSortSchema, optionValueRequestSchema, optionValueSchema, orderCanceledWebhookEventDataSchema, orderCanceledWebhookEventSchema, orderDiscountSchema, orderFlowActionResultSchema, orderFulfilledWebhookEventDataSchema, orderFulfilledWebhookEventSchema, orderItemFlowSchema, orderItemFulfillmentSchema, orderItemFulfillmentSnapshotResponseSchema, orderItemFulfillmentSnapshotSchema, orderItemListQuerySchema, orderItemMemoResultSchema, orderItemPageSchema, orderItemSchema, orderItemStatusSchema, orderListQuerySchema, orderSchema, orderSummaryPageSchema, orderSummarySchema, orderWebhookEventDataSchema, orderWebhookEventSchema, pageInfoSchema, pageQueryShape, pageSchema, parseOrderNo, parseWebhookEvent, payPalCredentialsInputSchema, paymentAttemptRecordSchema, paymentAttemptStatusSchema, paymentCredentialSetSchema, paymentFailureWarningSchema, paymentListQuerySchema, paymentProviderSchema, paymentProviderVerificationSchema, paymentRecordDetailSchema, paymentRecordPageSchema, paymentRecordSchema, paymentRecordStatusSchema, paymentRefundRecordSchema, paymentSettingsSchema, paymentStatusProviderSchema, paymentStatusSchema, pgEnvironmentSchema, pgPaymentMethodSchema, pgProviderResponseSchema, pgProviderSchema, pgVerificationResultSchema, pickupLocationRequestSchema, pickupLocationSchema, pickupLocationSnapshotSchema, planCodeSchema, planEntitlementsSchema, planErrorDetailsSchema, platformCodeSchema, pointAdjustmentRequestSchema, pointAdjustmentResultSchema, pointEarnOf, pointEarnRateBpSchema, pointEarningEnabled, pointEntrySchema, pointExpiresAtOf, pointHistoryQuerySchema, pointLotSchema, pointPolicyNoticeSchema, pointPolicySchema, pointRestoreExpiresAtOf, pointUseOf, pointUsePolicySchema, policyDocumentUrlSchema, policyVersionSchema, portOneChannelSchema, portOneCredentialsInputSchema, productCertificationsRequestSchema, productCertificationsSchema, productCreateRequestSchema, productCurrencyPriceSchema, productCurrencyPricesSchema, productFulfillmentCreateSchema, productFulfillmentResponseSchema, productFulfillmentSchema, productFulfillmentUpdateSchema, productImageRejection, productImageUrlSchema, productListQuerySchema, productLocalizationNeedsTranslation, productLocalizationRequestSchema, productLocalizationSchema, productNoticeRequestSchema, productNoticeSchema, productOutOfStockWebhookEventDataSchema, productOutOfStockWebhookEventSchema, productPatchRequestSchema, productRefundPolicyOverride, productRefundPolicyPatchSchema, productReplaceRequestSchema, productSchema, productSortSchema, productStatusSchema, productSummarySchema, productVariantRequestSchema, productVariantSchema, proratedPaidRefundBase, proratedPointRefund, proratedRefundBase, publicPlanSchema, publicPlansSchema, publishStorefrontVersionRequestSchema, purchaseDecisionExtendResultSchema, purchaseDecisionRequestResultSchema, purchaseEarnPolicySchema, purchaseEarnRateOf, putBrandBriefRequestSchema, quoteDelivery, quotePricing, rankBestSelling, refreshUserToken, refundPolicyPatchSchema, refundPolicySchema, rejectClaimRequestSchema, remoteAreaLabelOf, remoteAreaOf, remoteAreaSchema, remoteSurchargeOf, replaceStorefrontSourceRequestSchema, replayFlowRequestSchema, replayFlowResultSchema, requiresCollection, requiresShipping, resolvePointPolicy, resolveRefundPolicy, resolveShippingPolicy, resolvedFlowSchema, responsePlanCodeSchema, responsePointEntryTypeSchema, reviewListQuerySchema, reviewReportResultSchema, reviewRewardPointOf, reviewRewardPolicySchema, reviewSchema, reviewSortSchema, reviewWebhookEventDataSchema, reviewWebhookEventSchema, rollbackStorefrontRequestSchema, runStorefrontCheckRequestSchema, salesReportCurrencySchema, salesReportGroupBySchema, salesReportQuerySchema, salesReportRowSchema, salesReportSchema, salesTotalsSchema, saveFlowDraftRequestSchema, saveFlowSecretRequestSchema, saveLoginProviderRequestSchema, savedCustomInputRequestSchema, savedCustomInputSchema, savedOptionGroupRequestSchema, savedOptionGroupSchema, savedOptionSetCompositionSchema, savedOptionSetFromProductRequestSchema, savedOptionSetFromProductResultSchema, savedOptionSetListQuerySchema, savedOptionSetLocalizationRequestSchema, savedOptionSetLocalizationSchema, savedOptionSetRequestSchema, savedOptionSetSchema, savedOptionSetSortSchema, savedOptionValueRequestSchema, savedOptionValueSchema, scopeAccessSchema, scopesCoverEvent, searchStorefrontFilesRequestSchema, sellerAddressListQuerySchema, sellerAddressRequestSchema, sellerAddressSchema, sellerCancelPreviewSchema, sellerCustomerInquirySchema, sendAiMessageRequestSchema, sendAiMessageResponseSchema, setCalendarRequestSchema, setPlatformTestKeysRequestSchema, setStorefrontDeployApprovalRequestSchema, setStorefrontVisibilityRequestSchema, settleCouponShortfall, settlementDetailQuerySchema, settlementDetailSchema, settlementListQuerySchema, settlementStatusSchema, settlementSummarySchema, settlementWithDetailsSchema, shippingAddressSchema, shippingCurrencyPriceSchema, shippingCurrencyPricesSchema, shippingPolicyPatchSchema, shippingPolicySchema, simulateFlowRequestSchema, simulateFlowResultSchema, simulationStepSchema, splitRefund, starterSellerTaskSchema, starterStageSchema, starterStatusSchema, starterStoreInfoFieldSchema, stayRangeSchema, staySnapshotSchema, storeAppDetailSchema, storeAppSchema, storeCodeSchema, storeDraftPreviewSchema, storeDraftSchema, storeIndustrySchema, storeMemberRoleUpdatedSchema, storeMemberSchema, storePointPolicySchema, storeRoleSchema, storeSchema, storeScopeResourceSchema, storeSetupBriefSchema, storeShopTypeSchema, storeSubscriptionSchema, storeTemplateSchema, storedAdditionalCurrencyPriceSchema, storedProductCurrencyPriceSchema, storedShippingCurrencyPriceSchema, storefrontBuildDependenciesSchema, storefrontBuildListQuerySchema, storefrontBuildSchema, storefrontBuildStatusSchema, storefrontCheckSchema, storefrontCheckStatusSchema, storefrontCustomDomainStatusSchema, storefrontCustomHostnameProblem, storefrontDependencyFindingSchema, storefrontDeploymentLogSchema, storefrontDeploymentSchema, storefrontDeploymentStepSchema, storefrontDevLogsSchema, storefrontDnsRecordSchema, storefrontDomainSchema, storefrontDomainTxtNameOf, storefrontEditFailureSchema, storefrontEditPreviewLabelOf, storefrontEditPreviewSchema, storefrontEditSessionSchema, storefrontEditSessionStatusSchema, storefrontEditingSchema, storefrontFileConflictDetailsSchema, storefrontFileContentQuerySchema, storefrontFileContentSchema, storefrontFileDeleteResultSchema, storefrontFileEncodingSchema, storefrontFileEntrySchema, storefrontFileHashSchema, storefrontFileListQuerySchema, storefrontFileListSchema, storefrontFileMoveResultSchema, storefrontFilePathSchema, storefrontFileSearchResultSchema, storefrontFileWriteResultSchema, storefrontGitConnectStateSchema, storefrontGitMergeRequestSchema, storefrontGitMergeSchema, storefrontGitRepositorySchema, storefrontGitStatusSchema, storefrontHostingSchema, storefrontPreviewLinkSchema, storefrontProvisioningSchema, storefrontRuleResultSchema, storefrontRuleSeveritySchema, storefrontSiteDomainSchema, storefrontSiteDomainsSchema, storefrontSiteSchema, storefrontSiteSnapshotSchema, storefrontSiteStatusSchema, storefrontSlugAvailabilityQuerySchema, storefrontSlugAvailabilitySchema, storefrontSlugSchema, storefrontSourceArchivePartSchema, storefrontSourceArchiveQuerySchema, storefrontSourceBlobsResultSchema, storefrontSourceModeSchema, storefrontSourceRefSchema, storefrontSourceReplacedSchema, storefrontSourceSchema, storefrontSuspensionSchema, storefrontTemplateSchema, storefrontVerifyReportSchema, storefrontVersionCreatedSchema, storefrontVersionPreviewLabelOf, storefrontVersionSchema, storefrontVersionStatusSchema, storefrontVisibilitySchema, subscriptionLimitsSchema, subscriptionStatusSchema, subscriptionUsageSchema, toDecimalString, toMinor, tossPaymentsCredentialsInputSchema, trackingStageResponseSchema, trackingUpdateResultSchema, unknownWebhookEventSchema, updateCouponRequestSchema, updateLoginProviderRequestSchema, updateLoginSettingsRequestSchema, updateMarketRequestSchema, updateMemberRoleRequestSchema, updatePaymentProviderRequestSchema, updatePaymentSettingsRequestSchema, updatePointPolicyRequestSchema, updateStoreRequestSchema, updateStoreTemplateRequestSchema, uploadExtensionOf, uploadPurposeSchema, uploadRejection, uploadRequestSchema, uploadStorefrontSourceBlobsRequestSchema, uploadTicketSchema, upsertKakaoPayProviderRequestSchema, upsertNaverPayProviderRequestSchema, upsertPayPalProviderRequestSchema, 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 };
11497
+ export { AI_AGENT_NOTES_DIR, AI_AGENT_PHASES, AI_DESIGN_BOARDS_MAX, AI_DESIGN_BOARD_FILE_PATTERN, AI_DESIGN_BOARD_KINDS, AI_DESIGN_CANVAS_PATH, AI_DESIGN_CONFIRM_APPROVE, AI_DESIGN_DIR, AI_DESIGN_GUIDE_PATH, AI_DESIGN_VIEWPORTS, AI_MESSAGE_MAX_ATTACHMENTS, AI_MESSAGE_MAX_CHARS, AI_RUN_ACTIVE_STATUSES, AI_RUN_FILE_CHANGES_RETENTION_DAYS, AI_RUN_RESUME_CHOICE, AI_SETUP_CONFIRM_APPROVE, AI_SITEMAP_PATH, AI_TODOS_MAX, AI_TODO_STATUSES, AI_TOOL_CHANGE_LINE_MAX, AI_TOOL_CHANGE_RANGES_MAX, APPROVAL_ALREADY_DECIDED_CODE, APPROVAL_REQUIRED_CODE, APP_CAPABILITIES, APP_DEPLOY_KEY_PATTERN, APP_DEPLOY_KEY_PREFIX, APP_EVENTS_MAX, APP_EVENT_SCOPES, APP_EVENT_TYPES, APP_FLOW_EVENT_PATTERN, APP_FLOW_ITEMS_MAX, APP_FLOW_NOTIFICATION_PATTERN, APP_HANDLE_PATTERN, APP_HTTP_KEY_PATTERN, APP_ICON_CONTENT_TYPES, APP_ICON_MAX_BYTES, APP_ICON_MIN_PX, APP_LIFECYCLE_EVENT_TYPES, APP_NETWORK_DENIED_SUFFIXES, APP_NETWORK_HOSTS_MAX, APP_PUBLIC_HTTP_MAX, APP_README_MAX_BYTES, APP_RESERVED_HANDLES, APP_SCHEDULES_MAX, APP_SCHEDULE_INTERVALS, APP_SCHEDULE_NAME_PATTERN, APP_SECRETS_MAX, APP_SECRET_NAME_PATTERN, APP_SECRET_PATTERNS, APP_SERVER_BUNDLE_MAX_GZIP_BYTES, APP_SETTINGS_MAX_FIELDS, APP_SETTING_FIELD_TYPES, APP_SETTING_KEY_PATTERN, APP_STORAGE_KEY_PATTERN, APP_STORAGE_MAX_BYTES, APP_STORAGE_MAX_KEYS, APP_TOOL_NAME_PATTERN, APP_UI_MAX_BYTES, APP_UI_MAX_FILES, ApiError, ApprovalPendingError, BASE_CURRENCY, BRAND_BRIEF_MAX_REFERENCES, BUSINESS_INFO_MAX_LENGTH, BUSINESS_NUMBER_PATTERN, CASH_RECEIPT_STATUS_VALUES, CERTIFICATION_STATUSES, 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, CURRENCIES, CURRENCY_CODES, CUSTOM_INPUT_FORBIDDEN_WORDS, CUSTOM_INPUT_TYPES, DEDICATED_EASY_PAY_PROVIDER, DEFAULT_STORE_LOCALE, FULFILLMENT_METHODS, FULFILLMENT_METHODS_BY_TYPE, FULFILLMENT_METHOD_RULES, FULFILLMENT_RULES, INSTALLABLE_SCOPES, InvalidPriceUnitError, KAKAOPAY_TEST_CID, KNOWN_WEBHOOK_EVENT_TYPES, KRW_MONEY_RULES, MAX_ADDON_GROUPS, MAX_ANALYTICS_ALLOWED_ORIGINS, MAX_AUTO_TRANSITION_DAYS, MAX_CALENDAR_DAYS, MAX_CERTIFICATION_ITEMS, 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_INFO_SECTION_TITLE, MAX_INVENTORY_OPERATION_LINES, MAX_NOTICE_VALUE_LENGTH, MAX_OPTION_GROUPS, MAX_PICKUP_LOCATIONS, MAX_PRODUCT_IMAGES, MAX_PRODUCT_INFO_SECTIONS, MAX_SAVED_OPTION_SETS, MAX_SAVED_OPTION_SET_NAME, MAX_STAY_NIGHTS, MAX_VALUES_PER_GROUP, MAX_VARIANTS, MCP_TELEMETRY_MAX_RESULTS, MIN_PAYMENT_AMOUNT, NON_INSTALLABLE_SCOPES, NO_COUPON_SETTLEMENT, NO_SHIPPING_BUNDLE_KEY, PAYMENT_ROUTING_EXCLUSION_CODES, PAYPAL_CURRENCIES, PLATFORM_CODE_SETS, 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, SAYREN_API_BASE_URL, SAYREN_API_ORIGIN, SCOPE_DESCRIPTIONS, SHIPPING_POLICY_DEFAULTS, STARTER_SELLER_TASKS, STARTER_STAGES, STOREFRONT_BLOCKED_PATH_SEGMENTS, STOREFRONT_BUILD_STAGES, STOREFRONT_BUILD_TERMINAL_STATUSES, STOREFRONT_CHECK_TERMINAL_STATUSES, STOREFRONT_CLOSED_SITE_HOLD_DAYS, 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_DRAFT_ATTACHMENT_MAX_BYTES, STORE_DRAFT_MAX_ATTACHMENTS, STORE_DRAFT_RETENTION_DAYS, STORE_ROLE_SCOPES, STORE_SCOPE_RESOURCES, STORE_SESSION_KEYS, STORE_SHOP_TYPES, TEMPLATE_STORE_LOCKED_BUSINESS_FIELDS, 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, additionalCurrencyPriceSchema, additionalCurrencyPricesSchema, addonGroupRequestSchema, addonGroupSchema, addonValueRequestSchema, addonValueSchema, addressChangeRequestListSchema, addressTypeSchema, agentPolicyDecisionSchema, aiActivitySchema, aiAgentPhaseSchema, aiAttachmentSchema, aiChoiceOptionSchema, aiConversationFileChangesSchema, aiConversationSchema, aiConversationSummarySchema, aiDesignBoardSchema, aiDesignCanvasSchema, aiDesignConfirmBoardSchema, aiDesignSelectionSchema, aiFileChangeKindSchema, aiFocusAreaSchema, aiFocusSchema, aiMessagePartSchema, aiMessageSchema, aiPreviewSelectionSchema, aiRunChangesSchema, aiRunChangesStatusSchema, aiRunFileDiffSchema, aiRunRevertConflictDetailsSchema, aiRunRevertResultSchema, aiRunSchema, aiRunStatusSchema, aiSetupConfirmItemSchema, aiStreamAccessSchema, aiStreamEventSchema, aiStreamRecordSchema, aiTodoSchema, aiToolChangeSchema, 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, appArtifactUploadSchema, appBuildSchema, appBuildStageSchema, appCapabilitiesOf, appDeployKeyCreateSchema, appDeployKeyCreatedSchema, appDeployKeySchema, appDevTokenSchema, appDistributionSchema, appEventTypeSchema, appFlowEventSchema, appFlowEventSummarySchema, appFlowNotificationSchema, appFlowNotificationSummarySchema, appFlowParamSchema, appFlowSummaryOf, appHandleSchema, appHttpKeyMatches, appIconProblem, appInstallRequestSchema, appInstallationActivitySchema, appInstallationAppSchema, appInstallationRunSchema, appInstallationSchema, appInstallationSelfSchema, appInstallationSettingsSchema, appInstallationSettingsUpdateSchema, appInstallationStatusSchema, appInvocationSchema, appListingReviewSchema, appListingReviewStatusSchema, appListingSchema, appManifestProblems, appManifestSchema, appManifestWidens, appNetworkHostProblem, appNetworkHostSchema, appReleaseResultSchema, appRuntimeSchema, appScheduleIntervalLabel, appScheduleListOf, appScheduleSummarySchema, appScopeSchema, appSecretSummarySchema, appSessionSchema, appSettingFieldSchema, appStatusSchema, appStorageEntrySchema, appStorageKeysSchema, appStorageListQuerySchema, appStoragePutSchema, appToolCallSchema, appToolInputSchema, appToolListOf, appToolResultSchema, appToolSchema, appToolSummarySchema, appVersionSchema, appVersionStatusSchema, appVisibilitySchema, applyFlowOperationsRequestSchema, approvalDecisionRequestSchema, approvalListQuerySchema, approvalPageSchema, approvalRequestSchema, approvalStatusSchema, approveClaimResultSchema, assertSaleUnit, auditActorSchema, auditActorTypeSchema, auditLogListQuerySchema, auditLogOutcomeSchema, auditLogPageSchema, auditLogSchema, auditLogSourceSchema, bestSellingRuleOf, brandBriefProductSourceSchema, brandBriefReferenceSchema, brandBriefSchema, brandBriefViewSchema, buildAuthorizeUrl, buildQuery, bulkResultSchema, businessInfoPatchShape, businessInfoResponseShape, businessNumberSchema, calendarDateSchema, calendarDaySchema, calendarQuerySchema, cancelBySellerRequestSchema, cancelBySellerResultSchema, carrierSchema, cashReceiptSchema, categoryAttributeSchema, categoryCreateRequestSchema, categoryDeleteQuerySchema, categoryDeleteStrategySchema, categoryListQuerySchema, categoryLocalizationRequestSchema, categoryLocalizationSchema, categoryPatchRequestSchema, categoryProductSortSchema, categorySchema, categorySearchResultSchema, categoryTreeNodeSchema, categoryWithPathSchema, changeStorefrontSlugRequestSchema, changeStorefrontTemplateRequestSchema, changeTypeSchema, claimCollectCompleteRequestSchema, claimDetailSchema, claimFlowEditSessionRequestSchema, claimHoldResultSchema, claimListQuerySchema, claimReasonSchema, claimRedeliveryRequestSchema, claimReturnAddressSchema, claimSchema, claimStatusSchema, claimTypeSchema, claimWebhookEventDataSchema, claimWebhookEventSchema, collectionCreateRequestSchema, collectionListQuerySchema, collectionLocalizationRequestSchema, collectionLocalizationSchema, collectionPageSchema, collectionPatchRequestSchema, collectionPreviewRequestSchema, collectionPreviewSchema, collectionProductListQuerySchema, collectionProductSchema, collectionProductSortRequestSchema, collectionProductsAddRequestSchema, collectionProductsReplaceRequestSchema, collectionRuleCategoryIds, collectionRuleSchema, collectionRuleViewSchema, collectionRulesPredicate, collectionRulesSchema, collectionSchema, collectionStateCountsSchema, collectionStateOf, collectionStateSchema, commerceFlowCheckSchema, commerceFlowSchema, commerceFlowSummarySchema, commerceFlowVersionViewSchema, commerceNumberField, compareBySales, connectStorefrontGitRequestSchema, consentActionSchema, consentKindSchema, consentSourceSchema, couponBenefitSchema, couponConditionsInputSchema, couponConditionsSchema, couponDiscountOf, couponIssueListQuerySchema, couponIssueMethodSchema, couponIssueSchema, couponIssueStatusSchema, couponKindSchema, couponListQuerySchema, couponRedemptionListQuerySchema, couponRedemptionSchema, couponRejectReasonSchema, couponRuleSchema, couponSchema, couponStatsSchema, couponStatusSchema, couponTargetInputSchema, couponTargetSchema, createAiConversationRequestSchema, createAiConversationResponseSchema, createCommerceFlowRequestSchema, createCouponRequestSchema, createMarketRequestSchema, createPkcePair, createSellerCheckoutRequestSchema, createStoreClient, createStoreDraftRequestSchema, createStoreDraftResponseSchema, createStoreSession, createStorefrontEditPreviewLinkRequestSchema, createStorefrontPreviewLinkRequestSchema, createStorefrontSiteRequestSchema, createStorefrontVersionRequestSchema, currencyCodeSchema, currencyRefundFeesSchema, currencyShippingPolicySchema, currencySpecOf, customInputLabelForbiddenWord, customInputRequestSchema, customInputSchema, customInputValueSchema, customerAddressSchema, customerConsentListQuerySchema, customerConsentSchema, customerConsentStateSchema, customerConsentsSchema, customerCouponSchema, customerDelegationRequestSchema, customerDelegationSchema, customerDetailSchema, customerInquiryCategorySchema, customerInquiryListQuerySchema, customerListQuerySchema, customerOrderSchema, customerPointsSchema, customerSortSchema, customerStatsSchema, customerSummarySchema, customerWithdrawalBlockedDetailsSchema, defaultFulfillmentMethodOf, deleteStorefrontFileRequestSchema, deliveryBundleKeyOf, deliveryFeeWaiverSchema, deliveryInfoSchema, deliveryMethodSchema, deliveryStatusSchema, deliveryTypeSchema, descendantCategoryIdsOf, describeScope, devStoreSchema, developerAppCreateSchema, developerAppSchema, developerInstallationSchema, developerOrgSchema, developerStoreSchema, disableStorefrontHostingRequestSchema, discountRequestSchema, discountSchema, dispatchRequestSchema, easyPayProviderResponseSchema, easyPayProviderSchema, eventTypeSchema, exchangeAuthorizationCode, floorToSaleUnit, flowActionRequestSchema, flowActionResultSchema, flowActionSchema, flowAuthoringGuideSchema, flowDraftEdgesSchema, flowDraftNodeSchema, flowDraftNodesSchema, flowDraftOperationSchema, flowEditSessionViewSchema, flowFieldValueSchema, flowInputFieldSchema, flowIssueSchema, flowNodeIdSchema, flowNodeTypeDetailSchema, flowNodeTypesSchema, flowNotificationWebhookEventDataSchema, flowNotificationWebhookEventSchema, flowOperationsResultSchema, flowPresetDetailSchema, flowPresetSummarySchema, flowRunSchema, flowRunStepSchema, flowSecretNameSchema, flowSecretSchema, flowStateChangedWebhookEventDataSchema, flowStateChangedWebhookEventSchema, flowStateSchema, formatOrderNo, fromDecimalString, fulfillBulkRequestSchema, fulfillRequestSchema, fulfillmentMethodOf, fulfillmentMethodSchema, fulfillmentMethodsOf, fulfillmentRuleOf, fulfillmentTypeOf, fulfillmentTypeResponseSchema, fulfillmentTypeSchema, holdOrderItemRequestSchema, infoFieldSourceSchema, infoSchemaFieldSchema, infoSchemaSchema, infoSectionLocalizationRequestSchema, infoSectionLocalizationSchema, infoSectionRequestSchema, infoSectionSchema, inquiryListQuerySchema, inquirySchema, inquiryWebhookEventDataSchema, inquiryWebhookEventSchema, inventoryAdjustmentLineSchema, inventoryAdjustmentReasonSchema, inventoryAdjustmentRequestSchema, inventoryChangedWebhookEventDataSchema, inventoryChangedWebhookEventSchema, inventoryLevelListQuerySchema, inventoryLevelPageSchema, inventoryLevelSchema, inventoryLocationRequestSchema, inventoryLocationSchema, inventoryModeSchema, inventoryMovementKindSchema, inventoryMovementListQuerySchema, inventoryMovementPageSchema, inventoryMovementSchema, inventoryOperationResultSchema, inventoryTransferRequestSchema, invitationDeliveryStatusSchema, invitationListQuerySchema, invitationSchema, inviteMemberRequestSchema, isAiAgentNotesPath, isAiChoiceAnswer, isAiDesignPath, isAiWorkspaceDocPath, isCouponTargetLine, isCurrencyCode, isEditableStorefrontPath, isInstallableScope, isReservedStoreCode, isReservedStorefrontSlug, isSaleUnitPrice, isShowcaseStorefrontSlug, isStoreScope, isWebOrigin, issueCouponRequestSchema, issueCouponResultSchema, kakaoPayCredentialsInputSchema, linkStorefrontGitInstallationRequestSchema, liveGateConditionCodeSchema, liveGateConditionSchema, liveGateErrorDetailsSchema, liveGateSchema, localeCodeSchema, loginProviderSchema, loginProviderStatusSchema, loginProviderTestSchema, loginSettingsSchema, marketSchema, maskedSecretSchema, matchesCollectionRules, mcpRuleResultSchema, mcpToolEventSchema, migrateFlowVersionRequestSchema, migrateFlowVersionResultSchema, minPaymentOf, minorToMajor, moneyRulesOf, moveFlowStateRequestSchema, moveStorefrontFileRequestSchema, myAccountSchema, myStoreSchema, naverPayCredentialsInputSchema, nightsOf, normalizeBusinessNumber, normalizeCouponCode, normalizeLocale, normalizeStorefrontHostname, normalizeStorefrontPath, oauthTokenResponseSchema, openFulfillmentUnion, optionGroupKindSchema, optionGroupRequestSchema, optionGroupSchema, optionModelRequestSchema, optionModelSchema, optionSelectionSchema, optionSortSchema, optionValueRequestSchema, optionValueSchema, orderCanceledWebhookEventDataSchema, orderCanceledWebhookEventSchema, orderDiscountSchema, orderFlowActionResultSchema, orderFulfilledWebhookEventDataSchema, orderFulfilledWebhookEventSchema, orderItemFlowSchema, orderItemFulfillmentSchema, orderItemFulfillmentSnapshotResponseSchema, orderItemFulfillmentSnapshotSchema, orderItemListQuerySchema, orderItemMemoResultSchema, orderItemPageSchema, orderItemSchema, orderItemStatusSchema, orderListQuerySchema, orderSchema, orderSummaryPageSchema, orderSummarySchema, orderWebhookEventDataSchema, orderWebhookEventSchema, pageInfoSchema, pageQueryShape, pageSchema, parseOrderNo, parseWebhookEvent, payPalCredentialsInputSchema, paymentAttemptRecordSchema, paymentAttemptStatusSchema, paymentCredentialSetSchema, paymentFailureWarningSchema, paymentListQuerySchema, paymentProviderSchema, paymentProviderVerificationSchema, paymentRecordDetailSchema, paymentRecordPageSchema, paymentRecordSchema, paymentRecordStatusSchema, paymentRefundRecordSchema, paymentSettingsSchema, paymentStatusProviderSchema, paymentStatusSchema, pgEnvironmentSchema, pgPaymentMethodSchema, pgProviderResponseSchema, pgProviderSchema, pgVerificationResultSchema, pickupLocationRequestSchema, pickupLocationSchema, pickupLocationSnapshotSchema, planCodeSchema, planEntitlementsSchema, planErrorDetailsSchema, platformCodeSchema, pointAdjustmentRequestSchema, pointAdjustmentResultSchema, pointEarnOf, pointEarnRateBpSchema, pointEarningEnabled, pointEntrySchema, pointExpiresAtOf, pointHistoryQuerySchema, pointLotSchema, pointPolicyNoticeSchema, pointPolicySchema, pointRestoreExpiresAtOf, pointUseOf, pointUsePolicySchema, policyDocumentUrlSchema, policyVersionSchema, portOneChannelSchema, portOneCredentialsInputSchema, productCertificationsRequestSchema, productCertificationsSchema, productCreateRequestSchema, productCurrencyPriceSchema, productCurrencyPricesSchema, productFulfillmentCreateSchema, productFulfillmentResponseSchema, productFulfillmentSchema, productFulfillmentUpdateSchema, productImageRejection, productImageUrlSchema, productListQuerySchema, productLocalizationNeedsTranslation, productLocalizationRequestSchema, productLocalizationSchema, productNoticeRequestSchema, productNoticeSchema, productOutOfStockWebhookEventDataSchema, productOutOfStockWebhookEventSchema, productPatchRequestSchema, productRefundPolicyOverride, productRefundPolicyPatchSchema, productReplaceRequestSchema, productSchema, productSortSchema, productStatusSchema, productSummarySchema, productVariantRequestSchema, productVariantSchema, proratedPaidRefundBase, proratedPointRefund, proratedRefundBase, publicPlanSchema, publicPlansSchema, publishStorefrontVersionRequestSchema, purchaseDecisionExtendResultSchema, purchaseDecisionRequestResultSchema, purchaseEarnPolicySchema, purchaseEarnRateOf, putBrandBriefRequestSchema, quoteDelivery, quotePricing, rankBestSelling, refreshUserToken, refundPolicyPatchSchema, refundPolicySchema, rejectClaimRequestSchema, remoteAreaLabelOf, remoteAreaOf, remoteAreaSchema, remoteSurchargeOf, replaceStorefrontSourceRequestSchema, replayFlowRequestSchema, replayFlowResultSchema, requiresCollection, requiresShipping, resolvePointPolicy, resolveRefundPolicy, resolveShippingPolicy, resolvedFlowSchema, responsePlanCodeSchema, responsePointEntryTypeSchema, reviewListQuerySchema, reviewReportResultSchema, reviewRewardPointOf, reviewRewardPolicySchema, reviewSchema, reviewSortSchema, reviewWebhookEventDataSchema, reviewWebhookEventSchema, rollbackStorefrontRequestSchema, runStorefrontCheckRequestSchema, salesReportCurrencySchema, salesReportGroupBySchema, salesReportQuerySchema, salesReportRowSchema, salesReportSchema, salesTotalsSchema, saveFlowDraftRequestSchema, saveFlowSecretRequestSchema, saveLoginProviderRequestSchema, savedCustomInputRequestSchema, savedCustomInputSchema, savedOptionGroupRequestSchema, savedOptionGroupSchema, savedOptionSetCompositionSchema, savedOptionSetFromProductRequestSchema, savedOptionSetFromProductResultSchema, savedOptionSetListQuerySchema, savedOptionSetLocalizationRequestSchema, savedOptionSetLocalizationSchema, savedOptionSetRequestSchema, savedOptionSetSchema, savedOptionSetSortSchema, savedOptionValueRequestSchema, savedOptionValueSchema, scopeAccessSchema, scopesCoverEvent, searchStorefrontFilesRequestSchema, sellerAddressListQuerySchema, sellerAddressRequestSchema, sellerAddressSchema, sellerCancelPreviewSchema, sellerCheckoutLineSchema, sellerCheckoutPageSchema, sellerCheckoutSchema, sellerCustomerInquirySchema, sendAiMessageRequestSchema, sendAiMessageResponseSchema, setCalendarRequestSchema, setPlatformTestKeysRequestSchema, setStorefrontDeployApprovalRequestSchema, setStorefrontVisibilityRequestSchema, settleCouponShortfall, settlementDetailQuerySchema, settlementDetailSchema, settlementListQuerySchema, settlementStatusSchema, settlementSummarySchema, settlementWithDetailsSchema, shippingAddressSchema, shippingCurrencyPriceSchema, shippingCurrencyPricesSchema, shippingPolicyPatchSchema, shippingPolicySchema, simulateFlowRequestSchema, simulateFlowResultSchema, simulationStepSchema, splitRefund, starterSellerTaskSchema, starterStageSchema, starterStatusSchema, starterStoreInfoFieldSchema, stayRangeSchema, staySnapshotSchema, storeAppDetailSchema, storeAppSchema, storeCodeSchema, storeDraftPreviewSchema, storeDraftSchema, storeIndustrySchema, storeMemberRoleUpdatedSchema, storeMemberSchema, storePointPolicySchema, storeRoleSchema, storeSchema, storeScopeResourceSchema, storeSetupBriefSchema, storeShopTypeSchema, storeSubscriptionSchema, storeTemplateSchema, storedAdditionalCurrencyPriceSchema, storedProductCurrencyPriceSchema, storedShippingCurrencyPriceSchema, storefrontBuildDependenciesSchema, storefrontBuildListQuerySchema, storefrontBuildSchema, storefrontBuildStatusSchema, storefrontCheckSchema, storefrontCheckStatusSchema, storefrontCustomDomainStatusSchema, storefrontCustomHostnameProblem, storefrontDependencyFindingSchema, storefrontDeploymentLogSchema, storefrontDeploymentSchema, storefrontDeploymentStepSchema, storefrontDevLogsSchema, storefrontDnsRecordSchema, storefrontDomainSchema, storefrontDomainTxtNameOf, storefrontEditFailureSchema, storefrontEditPreviewLabelOf, storefrontEditPreviewSchema, storefrontEditSessionSchema, storefrontEditSessionStatusSchema, storefrontEditingSchema, storefrontFileConflictDetailsSchema, storefrontFileContentQuerySchema, storefrontFileContentSchema, storefrontFileDeleteResultSchema, storefrontFileEncodingSchema, storefrontFileEntrySchema, storefrontFileHashSchema, storefrontFileListQuerySchema, storefrontFileListSchema, storefrontFileMoveResultSchema, storefrontFilePathSchema, storefrontFileSearchResultSchema, storefrontFileWriteResultSchema, storefrontGitConnectStateSchema, storefrontGitMergeRequestSchema, storefrontGitMergeSchema, storefrontGitRepositorySchema, storefrontGitStatusSchema, storefrontHostingSchema, storefrontPreviewLinkSchema, storefrontProvisioningSchema, storefrontRuleResultSchema, storefrontRuleSeveritySchema, storefrontSiteDomainSchema, storefrontSiteDomainsSchema, storefrontSiteSchema, storefrontSiteSnapshotSchema, storefrontSiteStatusSchema, storefrontSlugAvailabilityQuerySchema, storefrontSlugAvailabilitySchema, storefrontSlugSchema, storefrontSourceArchivePartSchema, storefrontSourceArchiveQuerySchema, storefrontSourceBlobsResultSchema, storefrontSourceModeSchema, storefrontSourceRefSchema, storefrontSourceReplacedSchema, storefrontSourceSchema, storefrontSuspensionSchema, storefrontTemplateSchema, storefrontVerifyReportSchema, storefrontVersionCreatedSchema, storefrontVersionPreviewLabelOf, storefrontVersionSchema, storefrontVersionStatusSchema, storefrontVisibilitySchema, subscriptionLimitsSchema, subscriptionStatusSchema, subscriptionUsageSchema, toDecimalString, toMinor, tossPaymentsCredentialsInputSchema, trackingStageResponseSchema, trackingUpdateResultSchema, unknownWebhookEventSchema, updateCouponRequestSchema, updateLoginProviderRequestSchema, updateLoginSettingsRequestSchema, updateMarketRequestSchema, updateMemberRoleRequestSchema, updatePaymentProviderRequestSchema, updatePaymentSettingsRequestSchema, updatePointPolicyRequestSchema, updateStoreRequestSchema, updateStoreTemplateRequestSchema, uploadExtensionOf, uploadPurposeSchema, uploadRejection, uploadRequestSchema, uploadStorefrontSourceBlobsRequestSchema, uploadTicketSchema, upsertKakaoPayProviderRequestSchema, upsertNaverPayProviderRequestSchema, upsertPayPalProviderRequestSchema, 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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sayren/store-sdk",
3
- "version": "0.43.0",
3
+ "version": "0.45.0",
4
4
  "main": "./dist/index.mjs",
5
5
  "types": "./dist/index.d.mts",
6
6
  "exports": {
package/src/client.ts CHANGED
@@ -83,6 +83,12 @@ import {
83
83
  categoryTreeNodeSchema,
84
84
  categoryWithPathSchema,
85
85
  } from "./schemas/category";
86
+ import {
87
+ type CreateSellerCheckoutRequest,
88
+ createSellerCheckoutRequestSchema,
89
+ sellerCheckoutPageSchema,
90
+ sellerCheckoutSchema,
91
+ } from "./schemas/checkout";
86
92
  import {
87
93
  approveClaimResultSchema,
88
94
  type ClaimListParams,
@@ -2119,6 +2125,24 @@ export function createStoreClient(options: StoreClientOptions) {
2119
2125
  storeHttp.requestVoid("DELETE", path`/pickup-locations/${locationId}`),
2120
2126
  },
2121
2127
 
2128
+ /**
2129
+ * 셀러 작성 주문서 (이슈 #116) — 셀러가 줄·단가·유효 기한을 정해 만들고 `checkoutId`를 결제 링크로 보낸다.
2130
+ * 구매자는 스토어프론트에서 그 주문서로 결제한다(storefront-sdk `checkout.get`). 스코프 `order:r`·`order:rw`.
2131
+ */
2132
+ checkouts: {
2133
+ create: (body: CreateSellerCheckoutRequest) =>
2134
+ storeHttp.request("POST", "/checkouts", sellerCheckoutSchema, {
2135
+ body: createSellerCheckoutRequestSchema.parse(body),
2136
+ }),
2137
+ list: (query: { page?: number; size?: number } = {}) =>
2138
+ storeHttp.request("GET", "/checkouts", sellerCheckoutPageSchema, { query }),
2139
+ get: (checkoutId: string) =>
2140
+ storeHttp.request("GET", path`/checkouts/${checkoutId}`, sellerCheckoutSchema),
2141
+ /** `POST /v1/checkouts/{checkoutId}/expire` — 결제 대기 중인 주문서를 바로 만료시킨다 */
2142
+ expire: (checkoutId: string) =>
2143
+ storeHttp.request("POST", path`/checkouts/${checkoutId}/expire`, sellerCheckoutSchema),
2144
+ },
2145
+
2122
2146
  /**
2123
2147
  * 상점 플랫폼 AI 채팅 (이슈 #124) — 상점 플랫폼 전용(공개 문서 제외). 메시지는 202로 `streamId`를 돌려주고
2124
2148
  * 응답은 `streamUrl`(SSE, Bearer `streamToken`)로 받는다. 실행은 브라우저와 무관하게 서버에서 끝까지 돈다.
package/src/index.ts CHANGED
@@ -26,6 +26,7 @@ export * from "./schemas/apps";
26
26
  export * from "./schemas/audit";
27
27
  export * from "./schemas/auth";
28
28
  export * from "./schemas/category";
29
+ export * from "./schemas/checkout";
29
30
  export * from "./schemas/claim";
30
31
  export * from "./schemas/collection";
31
32
  export * from "./schemas/commerce-flow";
@@ -0,0 +1,134 @@
1
+ import * as z from "zod";
2
+ import { pageSchema } from "./common";
3
+ import { strictRequest } from "./strict";
4
+
5
+ /**
6
+ * 셀러 작성 주문서 (이슈 #116) — 셀러가 줄·단가·유효 기한을 정해 만들고, 구매자는 스토어프론트에서 그 주문서로 결제한다.
7
+ * 링크(주문서 id)를 가진 사람은 누구나 결제할 수 있다. 결제가 승인되면 일반 주문과 같은 주문이 생긴다.
8
+ */
9
+ export const sellerCheckoutLineSchema = z.object({
10
+ productId: z.string(),
11
+ optionId: z
12
+ .string()
13
+ .optional()
14
+ .describe("조합 id(`variants[].variantId`). 옵션 없는 상품은 생략"),
15
+ quantity: z.number().int().min(1).max(9999),
16
+ unitPrice: z
17
+ .number()
18
+ .int()
19
+ .min(0)
20
+ .optional()
21
+ .describe(
22
+ "이 줄의 단가(통화 최소 단위). 생략하면 상품의 현재 판매가(즉시할인·조합 추가금·추가 선택 추가금 반영)다. 주면 그 금액이 단가가 되고, 정가보다 낮으면 차액이 주문의 할인으로 남는다",
23
+ ),
24
+ addons: z
25
+ .array(z.object({ groupId: z.string(), valueId: z.string() }))
26
+ .max(20)
27
+ .optional()
28
+ .describe("고른 추가 선택(옵션명마다 하나). 스토어프론트 바로 구매와 같은 규칙이다"),
29
+ customInputs: z
30
+ .array(z.object({ inputId: z.string(), value: z.string().max(1000) }))
31
+ .max(20)
32
+ .optional()
33
+ .describe("직접 입력값. 스토어프론트 바로 구매와 같은 규칙이다"),
34
+ });
35
+
36
+ export type SellerCheckoutLineRequest = z.infer<typeof sellerCheckoutLineSchema>;
37
+
38
+ export const createSellerCheckoutRequestSchema = strictRequest(
39
+ z.object({
40
+ items: z.array(sellerCheckoutLineSchema).min(1).max(50),
41
+ expiresAt: z.iso
42
+ .datetime({ offset: true })
43
+ .describe("유효 기한(ISO 8601). 지금 이후여야 하고, 지나면 결제할 수 없다"),
44
+ fulfillmentMethod: z
45
+ .enum(["CARRIER", "DIRECT", "PICKUP", "PROVIDED"])
46
+ .optional()
47
+ .describe(
48
+ "이행 방식. 스토어프론트 주문서 생성과 같은 규칙이다. 생략하면 줄마다 상품 허용 방식의 첫 값이다",
49
+ ),
50
+ pickupLocationId: z
51
+ .string()
52
+ .optional()
53
+ .describe("방문 수령 장소. 스토어프론트 주문서 생성과 같은 규칙이다"),
54
+ trackInventory: z
55
+ .boolean()
56
+ .optional()
57
+ .default(true)
58
+ .describe(
59
+ "재고 추적. false면 주문서를 만들 때·결제할 때 재고를 보지 않고 빼지 않는다. 그 주문의 취소·반품도 재고를 돌려주지 않는다. 기본 true",
60
+ ),
61
+ couponsEnabled: z
62
+ .boolean()
63
+ .optional()
64
+ .default(false)
65
+ .describe("구매자가 이 주문서에 쿠폰을 쓸 수 있는가. 기본 false"),
66
+ pointsEnabled: z
67
+ .boolean()
68
+ .optional()
69
+ .default(false)
70
+ .describe("구매자가 이 주문서에 적립금을 쓸 수 있는가. 기본 false"),
71
+ }),
72
+ );
73
+
74
+ export type CreateSellerCheckoutRequest = z.input<typeof createSellerCheckoutRequestSchema>;
75
+
76
+ export const sellerCheckoutSchema = z.object({
77
+ checkoutId: z
78
+ .string()
79
+ .describe(
80
+ "주문서 id. 결제 링크(`checkoutUrl`)나 스토어프론트가 이 id로 주문서를 열어 결제한다(`GET /storefront/v1/checkout/{checkoutId}`). 추측할 수 없는 값이고, 가진 사람은 누구나 결제할 수 있다",
81
+ ),
82
+ status: z
83
+ .string()
84
+ .describe(
85
+ "`OPEN`(결제 대기) · `PAID`(결제 완료) · `EXPIRED`(만료). 값이 추가될 수 있어 문자열로 받는다",
86
+ ),
87
+ checkoutUrl: z
88
+ .string()
89
+ .describe(
90
+ "결제 링크 — sayren이 호스팅하는 결제 페이지(`https://checkout.sayren.io/{상점 코드}/{checkoutId}`)다. 스토어프론트가 없거나 이 화면을 구현하지 않은 상점도 이 링크로 결제받는다",
91
+ ),
92
+ currency: z.string(),
93
+ items: z.array(
94
+ z.object({
95
+ lineId: z.string(),
96
+ productId: z.string(),
97
+ productName: z.string(),
98
+ optionId: z.string().nullable(),
99
+ optionName: z.string().nullable(),
100
+ quantity: z.number().int(),
101
+ unitPrice: z.number().int(),
102
+ listUnitPrice: z
103
+ .number()
104
+ .int()
105
+ .describe("할인 전 단가. `unitPrice`보다 크면 차액이 할인이다"),
106
+ totalPrice: z.number().int(),
107
+ }),
108
+ ),
109
+ amounts: z.object({
110
+ productAmount: z.number().int(),
111
+ deliveryFee: z
112
+ .number()
113
+ .int()
114
+ .describe("배송지를 모르는 시점의 배송비. 제주·도서산간 추가 배송비는 결제할 때 더해진다"),
115
+ totalAmount: z.number().int(),
116
+ }),
117
+ requiresShipping: z
118
+ .boolean()
119
+ .describe(
120
+ "배송할 줄이 있는지. false면 배송지 없이 결제하고 배송비도 없다(배송 없는 상품만 담긴 주문서)",
121
+ ),
122
+ trackInventory: z.boolean(),
123
+ couponsEnabled: z.boolean(),
124
+ pointsEnabled: z.boolean(),
125
+ orderId: z.string().nullable().describe("결제로 만들어진 주문. 결제 전이면 null"),
126
+ createdAt: z.string(),
127
+ expiresAt: z.string(),
128
+ });
129
+
130
+ export type SellerCheckout = z.infer<typeof sellerCheckoutSchema>;
131
+
132
+ export const sellerCheckoutPageSchema = pageSchema(sellerCheckoutSchema);
133
+
134
+ export type SellerCheckoutPage = z.infer<typeof sellerCheckoutPageSchema>;