# 장바구니

## 장바구니 옵션변경

> &#x20; \## 기능설명\
> &#x20; \* 선택한 상품의 옵션을 변경합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 파라미터로 넘어온 \*\*장바구니 번호\*\*에 해당하는 데이터를 변경\
> &#x20; \* 단품번호, 수량을 업데이트\
> &#x20; \* 이미 담겨있는 단품으로 변경하면 이미 담겨있는 단품은 삭제하고 그 수량을 더해 업데이트\
> &#x20; \* 호출 시, 검증이 수행 되는데 실패 시 변경 불가\
> &#x20; \* 상품 판매 상태, 구매 가능 수량, 장바구니 최대 담기 개수 초과 확인\
> \---\
> &#x20; \## 수정 번호\
> &#x20; \* Release v2.00\_240711: 정기주문, 선물하기 사용 설정을 체크<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/optionChange":{"put":{"tags":["장바구니"],"summary":"장바구니 옵션변경","description":"  ## 기능설명\n  * 선택한 상품의 옵션을 변경합니다.\n  ---\n  ## 상세설명\n  * 파라미터로 넘어온 **장바구니 번호**에 해당하는 데이터를 변경\n  * 단품번호, 수량을 업데이트\n  * 이미 담겨있는 단품으로 변경하면 이미 담겨있는 단품은 삭제하고 그 수량을 더해 업데이트\n  * 호출 시, 검증이 수행 되는데 실패 시 변경 불가\n  * 상품 판매 상태, 구매 가능 수량, 장바구니 최대 담기 개수 초과 확인\n---\n  ## 수정 번호\n  * Release v2.00_240711: 정기주문, 선물하기 사용 설정을 체크\n","operationId":"optionChangeBasket","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterBasketRequest"}}},"required":true},"responses":{"200":{"description":"성공","content":{"*/*":{"schema":{"$ref":"#/components/schemas/RegisterBasketResponse"}}}},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"RegisterBasketRequest":{"required":["bsketGbCd","bsketInfGbCd","bsketNo","chlDtlNo","chlNo","goodsNo","infDispCtgNo","infDispCtgNoGbCd","itmNo","ordGbCd","repDispCtgNo"],"type":"object","properties":{"bsketNo":{"type":"integer","description":"장바구니번호","format":"int64"},"bsketInfGbCd":{"type":"string","description":"OM042(장바구니 유입 구분 코드)\n 10: BASKET_BUY(장바구니구매)\n,20: NOW_BUY(바로구매)\n,30: WISH_BUY(위시리스트구매)\n","enum":["BASKET_BUY","NOW_BUY","WISH_BUY"]},"bsketGbCd":{"type":"string","description":"OM001(장바구니 구분 코드)\n 10: HDEL(택배)\n 20: STORE_PICK_UP(매장수령)\n 30: QUICK_DELIVERY(퀵배송)\n 40: REGULAR_DELIVERY(정기주문)\n","enum":["HDEL","STORE_PICK_UP","QUICK_DELIVERY","REGULAR_DELIVERY"]},"chlNo":{"type":"string","description":"채널번호"},"chlDtlNo":{"type":"string","description":"채널상세번호"},"infDispCtgNoGbCd":{"type":"string","description":"OM041(유입전시카테고리번호구분코드)\n 01: DISPLAY_STORE(전시매장)\n,02: EXHIBITIONS(기획전)\n,06: SEARCH_SALES(검색매출)\n,07: SEARCH_AD_BANNER(검색광고배너)\n,08: FLOATING_BANNER(플로팅배너)\n,09: WISHLIST(위시리스트)\n,10: NONE(유입전시번호없음)\n","enum":["DISPLAY_STORE","EXHIBITIONS","SEARCH_SALES","SEARCH_AD_BANNER","FLOATING_BANNER","WISHLIST","NONE"]},"infDispCtgNo":{"type":"string","description":"유입전시카테고리번호"},"repDispCtgNo":{"type":"string","description":"대표전시카테고리번호"},"conrNo":{"type":"string","description":"코너번호"},"goodsNo":{"type":"string","description":"상품번호"},"itmNo":{"type":"string","description":"단품번호"},"bsketQty":{"minimum":1,"type":"integer","description":"장바구니 수량","format":"int32"},"ordGbCd":{"type":"string","description":"OM002(주문 구분 코드)\n 10: 일반주문\n , 20: 선물하기\n , 30: e-쿠폰\n , 40: 제휴\n","enum":["GENERAL_ORDER","GIVE_GIFT_ORDER","E_COUPON","SUBSCRIBE_ORDER"]}},"description":"장바구니 등록 요청 DTO"},"RegisterBasketResponse":{"type":"object","properties":{"bsketNo":{"type":"integer","description":"장바구니번호","format":"int64"}},"description":"장바구니 등록 응답 DTO"},"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 장바구니 삭제

> &#x20; \## 기능설명\
> &#x20; \* 선택한 상품들을 장바구니에서 삭제합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 파라미터로 넘어온 \*\*장바구니 번호\*\*에 해당하는 데이터를 삭제\
> &#x20; \* 주문완료여부를 'Y'로 업데이트\
> &#x20; \---\
> &#x20; \## 수정 번호\
> &#x20; \* Release v2.00\_240711: 정기주문, 선물하기 사용 설정을 체크<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/deleteBasket":{"put":{"tags":["장바구니"],"summary":"장바구니 삭제","description":"  ## 기능설명\n  * 선택한 상품들을 장바구니에서 삭제합니다.\n  ---\n  ## 상세설명\n  * 파라미터로 넘어온 **장바구니 번호**에 해당하는 데이터를 삭제\n  * 주문완료여부를 'Y'로 업데이트\n  ---\n  ## 수정 번호\n  * Release v2.00_240711: 정기주문, 선물하기 사용 설정을 체크\n","operationId":"deleteBasket","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BasketRequest"}}},"required":true},"responses":{"200":{"description":"성공"},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"BasketRequest":{"required":["bsketNoList"],"type":"object","properties":{"bsketGbCd":{"type":"string","description":"OM001(장바구니 구분 코드)\n 10: HDEL(택배)\n 20: STORE_PICK_UP(매장수령)\n 30: QUICK_DELIVERY(퀵배송)\n 40: REGULAR_DELIVERY(정기주문)\n","enum":["HDEL","STORE_PICK_UP","QUICK_DELIVERY","REGULAR_DELIVERY"]},"goodsNo":{"type":"string","description":"상품번호"},"itmNo":{"type":"string","description":"단품번호"},"bsketNoList":{"type":"array","description":"장바구니번호리스트","items":{"type":"integer","description":"장바구니번호리스트","format":"int64"}}},"description":"장바구니 조건 DTO"},"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 장바구니 상품 주문가능여부 체크

> &#x20; \## 기능설명\
> &#x20; \* 장바구니에서 바로구매 클릭 시, 주문서로 넘기기 전 선택한 장바구니 상품 데이터가 주문가능한지 검사합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 검증 실패 시, 주문서로 넘어가지 않고 장바구니에서 에러 메시지 노출\
> &#x20;   \* 상품: 상품 판매 상태, 구매 가능 수량, 재고, 예약상품 예약가능 일시, 비회원 성인상품 구매 불가, 성인상품 인증 여부\
> &#x20;   \* 주문자: 구매제한회원 확인, 연령 확인\
> &#x20; \---\
> &#x20; \## 수정번호\
> &#x20; \* Release v2.00\_240401 : 정기배송신청서 진입 시의 자동결제카드 체크 제거\
> &#x20; \* Release v2.00\_240711: 정기주문, 선물하기 사용 설정을 체크\
> &#x20; \* Release v2.00\_240729: 티켓 상품에 대한 유효성 검증 추가<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/validateBasket":{"post":{"tags":["장바구니"],"summary":"장바구니 상품 주문가능여부 체크","description":"  ## 기능설명\n  * 장바구니에서 바로구매 클릭 시, 주문서로 넘기기 전 선택한 장바구니 상품 데이터가 주문가능한지 검사합니다.\n  ---\n  ## 상세설명\n  * 검증 실패 시, 주문서로 넘어가지 않고 장바구니에서 에러 메시지 노출\n    * 상품: 상품 판매 상태, 구매 가능 수량, 재고, 예약상품 예약가능 일시, 비회원 성인상품 구매 불가, 성인상품 인증 여부\n    * 주문자: 구매제한회원 확인, 연령 확인\n  ---\n  ## 수정번호\n  * Release v2.00_240401 : 정기배송신청서 진입 시의 자동결제카드 체크 제거\n  * Release v2.00_240711: 정기주문, 선물하기 사용 설정을 체크\n  * Release v2.00_240729: 티켓 상품에 대한 유효성 검증 추가\n","operationId":"validateBasket","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ValidateBasketRequest"}}},"required":true},"responses":{"200":{"description":"성공"},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"ValidateBasketRequest":{"required":["bsketGbCd","bsketNoList","ordGbCd"],"type":"object","properties":{"ordGbCd":{"type":"string","description":"OM002(주문 구분 코드)\n 10: 일반주문\n , 20: 선물하기\n , 30: e-쿠폰\n , 40: 제휴\n","enum":["GENERAL_ORDER","GIVE_GIFT_ORDER","E_COUPON","SUBSCRIBE_ORDER"]},"bsketGbCd":{"type":"string","description":"OM001(장바구니 구분 코드)\n 10: HDEL(택배)\n 20: STORE_PICK_UP(매장수령)\n 30: QUICK_DELIVERY(퀵배송)\n 40: REGULAR_DELIVERY(정기주문)\n","enum":["HDEL","STORE_PICK_UP","QUICK_DELIVERY","REGULAR_DELIVERY"]},"bsketNoList":{"type":"array","description":"장바구니번호리스트","items":{"type":"integer","description":"장바구니번호리스트","format":"int64"}}}},"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 장바구니 등록

> &#x20; \## 기능설명\
> &#x20; \* 선택한 상품을 장바구니에 등록합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 비회원은 최초 등록 시, 세션번호를 생성하여 쿠키에 저장\
> &#x20; \* 바로구매, 장바구니 담기 수행 시, 호출\
> &#x20; \* 호출 시, 검증이 수행 되는데 실패 시 등록 불가\
> &#x20;   \* 공통: 상품 판매 상태, 구매 가능 수량\
> &#x20;   \* 바로구매: 상품 재고, 예약 상품 예약 가능 일시, 비회원 성인 상품 구매 불가, 성인 상품 인증 여부, 배송비 정책 존재 여부, 주문자 구매제한회원 여부/연령\
> &#x20;   \* 장바구니 담기: 배송비 정책 존재 여부, 장바구니 최대 담기 개수 초과 확인\
> &#x20; \---\
> &#x20; \## 특이사항\
> &#x20; \* 바로구매거나 장바구니 담기 케이스에서 새로운 상품이 INSERT되었을 때, INSERT된 ROW의 \*\*장바구니 번호(BSKET\_NO)\*\* 리턴(기존 상품 수량 UPDATE일 때는 NULL 리턴)\
> &#x20; \* 장바구니에 담을 수 있는 최대 수량은 공통코드 ST002, 코드"10"의 참조1값입니다.\
> &#x20; \* 등록된 장바구니의 보관기간은 공통코드 ST003, 코드"10"의 참조1값입니다. 보관기간이 지나면 배치로 삭제됩니다.\
> &#x20; \---\
> &#x20; \## 수정 번호\
> &#x20; \* Release v2.00\_240711: 정기주문, 선물하기 사용 설정을 체크\
> &#x20; \* Release v2.00\_240729: 티켓 상품에 대한 유효성 검증 추가<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/registerBasket":{"post":{"tags":["장바구니"],"summary":"장바구니 등록","description":"  ## 기능설명\n  * 선택한 상품을 장바구니에 등록합니다.\n  ---\n  ## 상세설명\n  * 비회원은 최초 등록 시, 세션번호를 생성하여 쿠키에 저장\n  * 바로구매, 장바구니 담기 수행 시, 호출\n  * 호출 시, 검증이 수행 되는데 실패 시 등록 불가\n    * 공통: 상품 판매 상태, 구매 가능 수량\n    * 바로구매: 상품 재고, 예약 상품 예약 가능 일시, 비회원 성인 상품 구매 불가, 성인 상품 인증 여부, 배송비 정책 존재 여부, 주문자 구매제한회원 여부/연령\n    * 장바구니 담기: 배송비 정책 존재 여부, 장바구니 최대 담기 개수 초과 확인\n  ---\n  ## 특이사항\n  * 바로구매거나 장바구니 담기 케이스에서 새로운 상품이 INSERT되었을 때, INSERT된 ROW의 **장바구니 번호(BSKET_NO)** 리턴(기존 상품 수량 UPDATE일 때는 NULL 리턴)\n  * 장바구니에 담을 수 있는 최대 수량은 공통코드 ST002, 코드\"10\"의 참조1값입니다.\n  * 등록된 장바구니의 보관기간은 공통코드 ST003, 코드\"10\"의 참조1값입니다. 보관기간이 지나면 배치로 삭제됩니다.\n  ---\n  ## 수정 번호\n  * Release v2.00_240711: 정기주문, 선물하기 사용 설정을 체크\n  * Release v2.00_240729: 티켓 상품에 대한 유효성 검증 추가\n","operationId":"registerBasket","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RegisterBasketRequest"}}},"required":true},"responses":{"200":{"description":"성공","content":{"*/*":{"schema":{"$ref":"#/components/schemas/RegisterBasketResponse"}}}},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"RegisterBasketRequest":{"required":["bsketGbCd","bsketInfGbCd","bsketNo","chlDtlNo","chlNo","goodsNo","infDispCtgNo","infDispCtgNoGbCd","itmNo","ordGbCd","repDispCtgNo"],"type":"object","properties":{"bsketNo":{"type":"integer","description":"장바구니번호","format":"int64"},"bsketInfGbCd":{"type":"string","description":"OM042(장바구니 유입 구분 코드)\n 10: BASKET_BUY(장바구니구매)\n,20: NOW_BUY(바로구매)\n,30: WISH_BUY(위시리스트구매)\n","enum":["BASKET_BUY","NOW_BUY","WISH_BUY"]},"bsketGbCd":{"type":"string","description":"OM001(장바구니 구분 코드)\n 10: HDEL(택배)\n 20: STORE_PICK_UP(매장수령)\n 30: QUICK_DELIVERY(퀵배송)\n 40: REGULAR_DELIVERY(정기주문)\n","enum":["HDEL","STORE_PICK_UP","QUICK_DELIVERY","REGULAR_DELIVERY"]},"chlNo":{"type":"string","description":"채널번호"},"chlDtlNo":{"type":"string","description":"채널상세번호"},"infDispCtgNoGbCd":{"type":"string","description":"OM041(유입전시카테고리번호구분코드)\n 01: DISPLAY_STORE(전시매장)\n,02: EXHIBITIONS(기획전)\n,06: SEARCH_SALES(검색매출)\n,07: SEARCH_AD_BANNER(검색광고배너)\n,08: FLOATING_BANNER(플로팅배너)\n,09: WISHLIST(위시리스트)\n,10: NONE(유입전시번호없음)\n","enum":["DISPLAY_STORE","EXHIBITIONS","SEARCH_SALES","SEARCH_AD_BANNER","FLOATING_BANNER","WISHLIST","NONE"]},"infDispCtgNo":{"type":"string","description":"유입전시카테고리번호"},"repDispCtgNo":{"type":"string","description":"대표전시카테고리번호"},"conrNo":{"type":"string","description":"코너번호"},"goodsNo":{"type":"string","description":"상품번호"},"itmNo":{"type":"string","description":"단품번호"},"bsketQty":{"minimum":1,"type":"integer","description":"장바구니 수량","format":"int32"},"ordGbCd":{"type":"string","description":"OM002(주문 구분 코드)\n 10: 일반주문\n , 20: 선물하기\n , 30: e-쿠폰\n , 40: 제휴\n","enum":["GENERAL_ORDER","GIVE_GIFT_ORDER","E_COUPON","SUBSCRIBE_ORDER"]}},"description":"장바구니 등록 요청 DTO"},"RegisterBasketResponse":{"type":"object","properties":{"bsketNo":{"type":"integer","description":"장바구니번호","format":"int64"}},"description":"장바구니 등록 응답 DTO"},"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 장바구니 병합

> &#x20; \## 기능설명\
> &#x20; \* 로그인 시에, 비회원일 때 담았던 장바구니 상품들을 로그인한 회원 장바구니로 합칩니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 쿠키에 저장된 세션번호로 비회원 장바구니 상품 조회\
> &#x20; \* 장바구니유입구분코드(OM042)가 바로구매인 데이터들은 로그인한 회원번호로 업데이트\
> &#x20; \* 장바구니유입구분코드(OM042)가 장바구니 담기, 위시리스트인 데이터들은 기존 데이터 삭제 후 로그인 한 회원 데이터로 새로 생성<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/combineBasket":{"post":{"tags":["장바구니"],"summary":"장바구니 병합","description":"  ## 기능설명\n  * 로그인 시에, 비회원일 때 담았던 장바구니 상품들을 로그인한 회원 장바구니로 합칩니다.\n  ---\n  ## 상세설명\n  * 쿠키에 저장된 세션번호로 비회원 장바구니 상품 조회\n  * 장바구니유입구분코드(OM042)가 바로구매인 데이터들은 로그인한 회원번호로 업데이트\n  * 장바구니유입구분코드(OM042)가 장바구니 담기, 위시리스트인 데이터들은 기존 데이터 삭제 후 로그인 한 회원 데이터로 새로 생성\n","operationId":"combineBsket","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"responses":{"200":{"description":"성공"},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 장바구니 총 수량 조회

> &#x20; \## 기능설명\
> &#x20; \* 비회원 혹은 현재 로그인 한 회원의 장바구니 총 수량을 조회합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 회원은 \*\*회원번호\*\*로 조회\
> &#x20; \* 비회원은 쿠키에 저장되어 있는 \*\*세션번호\*\*로 조회\
> &#x20; \---\
> &#x20; \## 수정번호\
> &#x20; \* Release v2.00\_240425: 장바구니 총 수량 조회 조건에 사이트 번호 추가<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/totBsketCnt":{"get":{"tags":["장바구니"],"summary":"장바구니 총 수량 조회","description":"  ## 기능설명\n  * 비회원 혹은 현재 로그인 한 회원의 장바구니 총 수량을 조회합니다.\n  ---\n  ## 상세설명\n  * 회원은 **회원번호**로 조회\n  * 비회원은 쿠키에 저장되어 있는 **세션번호**로 조회\n  ---\n  ## 수정번호\n  * Release v2.00_240425: 장바구니 총 수량 조회 조건에 사이트 번호 추가\n","operationId":"getBasketTotalCount","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"responses":{"200":{"description":"성공","content":{"*/*":{"schema":{"type":"integer","format":"int32"}}}},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 가장 최근에 담은 장바구니 구분(OM001) 조회

> &#x20; \## 기능설명\
> &#x20; \* 가장 최근에 담은 장바구니 구분(OM001)을 조회합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 비회원은 장바구니가 구분되어 있지 않아 해당하지 않으며 회원의 경우는 \*\*회원번호\*\*로 조회\
> &#x20; \* 주문완료여부가 'N', 장바구니유입구분코드(OM042)가 \[장바구니 담기, 위시리스트]인 장바구니 데이터<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/getRecentBasketType":{"get":{"tags":["장바구니"],"summary":"가장 최근에 담은 장바구니 구분(OM001) 조회","description":"  ## 기능설명\n  * 가장 최근에 담은 장바구니 구분(OM001)을 조회합니다.\n  ---\n  ## 상세설명\n  * 비회원은 장바구니가 구분되어 있지 않아 해당하지 않으며 회원의 경우는 **회원번호**로 조회\n  * 주문완료여부가 'N', 장바구니유입구분코드(OM042)가 [장바구니 담기, 위시리스트]인 장바구니 데이터\n","operationId":"getRecentBasketType","parameters":[{"name":"Authorization","in":"header","description":"Access Token","required":false}],"responses":{"200":{"description":"성공","content":{"*/*":{"schema":{"type":"string"}}}},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```

## 장바구니 조회

> &#x20; \## 기능설명\
> &#x20; \* 장바구니에 담겨있는 상품을 조회합니다.\
> &#x20; \---\
> &#x20; \## 상세설명\
> &#x20; \* 회원은 \*\*회원번호\*\*로 조회\
> &#x20; \* 비회원은 쿠키에 저장되어 있는 \*\*세션번호\*\*로 조회\
> &#x20; \* 주문완료여부가 'N', 장바구니유입구분코드(OM042)가 \[장바구니 담기, 위시리스트]인 장바구니 데이터\
> &#x20; \* 배송그룹으로 묶여서 조회\
> &#x20; \* 상품은 \*\*1. 배송처리방법이 센터배송 2. 장바구니 담은 최신 순\*\*으로 정렬 우선 순위를 갖고 우선 순위가 높은 상품이 포함된 배송그룹 순으로 정렬\
> &#x20; \* 같은 배송정책번호의 상품 중 선택 여부에 따라 조건부무료 배송비 계산하기 위해 배송비금액(dlexAmt) 가공하지 않는다\
> &#x20; \---\
> &#x20; \## 수정번호\
> &#x20; \* Release v2.00\_240425: 장바구니 조회 조건 사이트 번호 추가\
> &#x20; \* Release v2.00\_241025: 조건부무료 상품의 조건충족에 따른 배송비 계산하지 않도록 수정<br>

```json
{"openapi":"3.0.1","info":{"title":"X2BEE Order API","version":"v1"},"servers":[{"url":"https://api-order.x2bee.com/api/order/","description":"prd"}],"paths":{"/v1/basket/getBasket":{"get":{"tags":["장바구니"],"summary":"장바구니 조회","description":"  ## 기능설명\n  * 장바구니에 담겨있는 상품을 조회합니다.\n  ---\n  ## 상세설명\n  * 회원은 **회원번호**로 조회\n  * 비회원은 쿠키에 저장되어 있는 **세션번호**로 조회\n  * 주문완료여부가 'N', 장바구니유입구분코드(OM042)가 [장바구니 담기, 위시리스트]인 장바구니 데이터\n  * 배송그룹으로 묶여서 조회\n  * 상품은 **1. 배송처리방법이 센터배송 2. 장바구니 담은 최신 순**으로 정렬 우선 순위를 갖고 우선 순위가 높은 상품이 포함된 배송그룹 순으로 정렬\n  * 같은 배송정책번호의 상품 중 선택 여부에 따라 조건부무료 배송비 계산하기 위해 배송비금액(dlexAmt) 가공하지 않는다\n  ---\n  ## 수정번호\n  * Release v2.00_240425: 장바구니 조회 조건 사이트 번호 추가\n  * Release v2.00_241025: 조건부무료 상품의 조건충족에 따른 배송비 계산하지 않도록 수정\n","operationId":"getBasket","parameters":[{"name":"request","in":"query","required":true,"schema":{"$ref":"#/components/schemas/GetBasketRequest"}},{"name":"Authorization","in":"header","description":"Access Token","required":false}],"responses":{"200":{"description":"성공","content":{"*/*":{"schema":{"$ref":"#/components/schemas/BasketResponse"}}}},"900":{"description":"업무처리 오류 내용","content":{"*/*":{"schema":{"$ref":"#/components/schemas/Response"}}}}}}}},"components":{"schemas":{"GetBasketRequest":{"required":["bsketGbCd"],"type":"object","properties":{"ordMediaCd":{"type":"string","description":"주문매체코드"},"bsketGbCd":{"type":"string","description":"장바구니구분코드"}}},"BasketResponse":{"type":"object","properties":{"groupList":{"type":"array","description":"배송그룹 리스트","items":{"$ref":"#/components/schemas/DlvGrpInfo"}},"countList":{"type":"array","description":"택배 장바구니 수량","items":{"$ref":"#/components/schemas/BasketCount"}}},"description":"장바구니 조회 응답 DTO"},"DlvGrpInfo":{"required":["basketGoodsList","deliKindCd","deliMethodCd","deliNo","deliProcTypCd","dlvAmtInfoList"],"type":"object","properties":{"dlvpSeq":{"type":"string","description":"배송지순번"},"deliNo":{"type":"string","description":"합배송번호"},"deliKindCd":{"type":"string","description":"LO009(배송종류코드)\n 10: NORMAL_DELIVERY(일반배송)\n,20: RESERVATION_DELIVERY(예약배송)\n","enum":["NORMAL_DELIVERY","RESERVATION_DELIVERY"]},"deliProcTypCd":{"type":"string","description":"PR008(배송처리유형코드)\n 10: CNTR_DLV(센터배송)\n,20: CORP_DLV(업체배송)\n,30: E_COUPON_DLV(e-쿠폰배송)\n","enum":["CNTR_DLV","CORP_DLV","E_COUPON_DLV"]},"deliMethodCd":{"type":"string","description":"        LO010(배송방법코드)\n        * 10 : 택배배송\n        * 30 : 매장수령\n        * 40 : 퀵배송\n        * 50 : 해외배송\n        * 60 : 무배송\n","enum":["COURIER_DELIVERY","FOUR_PM","STORE_PICK_UP","QUICK_DELIVERY","OVERSEAS_DELIVERY","NON_DELIVERY"]},"basketGoodsList":{"type":"array","description":"장바구니상품정보","items":{"$ref":"#/components/schemas/BasketGoods"}},"dlvAmtInfoList":{"type":"array","description":"배송비정보","items":{"$ref":"#/components/schemas/DlvAmtInfo"}}},"description":"배송그룹정보 DTO"},"BasketGoods":{"type":"object","properties":{"goodsNo":{"type":"string","description":"상품번호"},"deliProcTypCd":{"type":"string","description":"PR008(배송처리유형코드)\n 10: CNTR_DLV(센터배송)\n,20: CORP_DLV(업체배송)\n,30: E_COUPON_DLV(e-쿠폰배송)\n","enum":["CNTR_DLV","CORP_DLV","E_COUPON_DLV"]},"deliPolcNo":{"type":"string","description":"배송정책번호"},"deliNo":{"type":"string","description":"배송번호"},"entrNo":{"type":"string","description":"협력사번호"},"ordQty":{"type":"integer","description":"주문수량","format":"int32"},"salePrc":{"type":"integer","description":"판매가","format":"int64"},"dcAmt":{"type":"integer","description":"할인가","format":"int64"},"sysModDtm":{"type":"string","description":"시스템수정시간","format":"date-time"},"itmNo":{"type":"string","description":"단품번호"},"bsketNo":{"type":"integer","description":"장바구니번호","format":"int64"},"chlNo":{"type":"string","description":"채널번호"},"chlDtlNo":{"type":"string","description":"채널상세번호"},"infDispCtgNoGbCd":{"type":"string","description":"유입전시카테고리번호구분코드(OM041)"},"infDispCtgNo":{"type":"string","description":"유입전시카테고리번호"},"repDispCtgNo":{"type":"string","description":"대표전시카테고리번호"},"conrNo":{"type":"string","description":"코너번호"},"bsketQty":{"type":"integer","description":"장바구니 수량","format":"int32"},"goodsNm":{"type":"string","description":"상품명"},"stdCtgNo":{"type":"string","description":"표준카테고리번호"},"goodsCompCd":{"type":"string","description":"상품구성코드(PR001)"},"goodsTypCd":{"type":"string","description":"상품유형코드(PR002)"},"saleMethCd":{"type":"string","description":"판매방식코드(PR003)"},"brandNo":{"type":"string","description":"브랜드번호"},"brandNm":{"type":"string","description":"브랜드명"},"buyrAgeLmtCd":{"type":"string","description":"구매연령제한코드"},"dispYn":{"type":"string","description":"전시여부"},"saleStatCd":{"type":"string","description":"판매상태코드(PR005)"},"saleStrDtm":{"type":"string","description":"판매시작일시","format":"date-time"},"saleEndDtm":{"type":"string","description":"판매종료일시","format":"date-time"},"buyTypCd":{"type":"string","description":"매입유형코드(PR006)"},"taxGbCd":{"type":"string","description":"과면세구분코드(PR007)"},"stkMgrYn":{"type":"string","description":"재고관리여부"},"buyQtyLmtYn":{"type":"string","description":"구매수량제한여부"},"minLmtQty":{"type":"integer","description":"최소제한수량","format":"int32"},"maxLmtQty":{"type":"integer","description":"최대제한수량","format":"int32"},"safeStkNotiYn":{"type":"string","description":"안전재고알림여부"},"deliGoodsGbCd":{"type":"string","description":"배송상품구분코드(PR010)"},"deliWayCd":{"type":"string","description":"배송수단코드(PR009)"},"deliPsbRgnCd":{"type":"string","description":"배송가능지역코드(PR030)"},"deliDday":{"type":"integer","description":"배송기일","format":"int64"},"bpckPsbYn":{"type":"string","description":"합포장가능여부"},"rtnPsbYn":{"type":"string","description":"반품가능여부"},"exchPsbYn":{"type":"string","description":"교환가능여부"},"supPcost":{"type":"integer","description":"공급원가","format":"int64"},"norPrc":{"type":"integer","description":"정상가","format":"int64"},"preSalePrc":{"type":"integer","description":"종전판매가","format":"int64"},"mrgnRate":{"type":"number","description":"마진율","format":"double"},"payMeanInfo":{"type":"string","description":"결제수단"},"itmNm":{"type":"string","description":"단품명"},"stkQty":{"type":"integer","description":"단품수량","format":"int64"},"prestNm":{"type":"string","description":"증정품명"},"rsvStrtDtm":{"type":"string","description":"예약시작일시","format":"date-time"},"rsvEndDtm":{"type":"string","description":"예약종료일시","format":"date-time"},"fwdidcPrarDy":{"type":"string","description":"출고지시예정일자","format":"date"},"hsCd":{"type":"string","description":"품목분류코드"},"wishYn":{"type":"string","description":"위시리스트 여부"},"maxDcAmt":{"type":"integer","description":"최대혜택금액","format":"int64"},"goodsImg":{"type":"string","description":"상품이미지"},"itmSaleStatCd":{"type":"string","description":"단품판매상태코드(PR005)"},"gvgfPsbYn":{"type":"string","description":"선물하기가능여부"},"rglrDeliGoodsYn":{"type":"string","description":"정기배송상품여부"},"sngGoodsYn":{"type":"string","description":"단일상품여부"},"marketingDisplayNo":{"type":"string","description":"기획전번호"},"entrGoodsNo":{"type":"string","description":"협력사상품번호"},"entrItmNo":{"type":"string","description":"협력사단품번호"},"ordCnclPsbYn":{"type":"string","description":"주문취소가능여부"},"wthdYn":{"type":"string","description":"회수여부"},"frgnDirPurGoodsYn":{"type":"string","description":"해외직구상품여부"}},"description":"장바구니 상품 DTO"},"DlvAmtInfo":{"required":["aplyAdtnAmt","deliPolcNo","dlexAmt","dlexTypCd","entrNo","ordCostGbCd","stdAdtnAmt"],"type":"object","properties":{"ordCostGbCd":{"type":"string","description":"OM043(주문비용구분코드)\n 10: 배송비\n , 20: 회수반품비\n , 30: 교환배송비\n , 40: 추가배송비\n","enum":["DELIVERY_FEE","RETURN_FEE","EXCHANGE_FEE","EXTRA_FEE"]},"dlexTypCd":{"type":"string","description":"배송비유형코드(VD005)","enum":["FREE","CHARGED","CONDITIONAL_FREE"]},"stdAdtnAmt":{"type":"integer","description":"기준부가비용금액","format":"int64"},"dlexAmt":{"type":"integer","description":"배송비금액","format":"int64"},"aplyAdtnAmt":{"type":"integer","description":"적용부가비용금액","format":"int64"},"trdTypCd":{"type":"string","description":"거래유형코드(VD002)"},"entrNo":{"type":"string","description":"협력사번호"},"deliPolcNo":{"type":"string","description":"배송정책번호"},"dlvBenefitInfo":{"$ref":"#/components/schemas/DlvBenefitInfo"}},"description":"배송비정보 DTO"},"DlvBenefitInfo":{"required":["cpnIsuNo","entrChrgRate","ourChrgRate","promoNm","promoNo","promoTypCd"],"type":"object","properties":{"promoNo":{"type":"string","description":"프로모션번호"},"promoNm":{"type":"string","description":"프로모션명"},"promoTypCd":{"type":"string","description":"프로모션 유형 코드(MK002)\n 11 : 상품할인쿠폰\n , 12 : 장바구니쿠폰\n , 13 : 중복할인쿠폰\n , 14 : 무료배송쿠폰\n , 15 : 무료반품쿠폰\n , 20 : 임직원할인\n , 21 : 상품즉시할인\n , 40 : 상품마일리지\n","enum":["11","12","13","14","15","20","21","40"]},"ourChrgRate":{"type":"integer","description":"자사분담률","format":"int32"},"entrChrgRate":{"type":"integer","description":"협력사분담률","format":"int32"},"cpnIsuNo":{"type":"string","description":"쿠폰발급번호"},"ordCostGbCd":{"type":"string","description":"비용구분코드(OM043)"}},"description":"배송혜택정보","nullable":true},"BasketCount":{"type":"object","properties":{"bsketGbCd":{"type":"string"},"count":{"type":"integer","format":"int32"}},"description":"택배 장바구니 수량"},"Response":{"type":"object","properties":{"timestamp":{"type":"string","description":"result time","format":"date-time"},"code":{"type":"string","description":"result code"},"message":{"type":"string","description":"result message"},"isProcess":{"type":"boolean","description":"process check"},"payload":{"type":"object","description":"payload"},"error":{"type":"boolean","description":"is error"},"errors":{"type":"array","description":"validation error list","items":{"$ref":"#/components/schemas/ValidationError"}}}},"ValidationError":{"type":"object","properties":{"field":{"type":"string","description":"field"},"message":{"type":"string","description":"field message"}},"description":"validation error list"}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://tech.x2bee.com/api/store-front-api/order-api/undefined-2.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
