diff --git a/src/services/api/v1/cart.ts b/src/services/api/v1/cart.ts index cb914568..56edae80 100644 --- a/src/services/api/v1/cart.ts +++ b/src/services/api/v1/cart.ts @@ -1,4 +1,4 @@ -import { CartResponse } from 'types/cart'; +import { CartResponse, CartCountResponse } from 'types/cart'; import { apiV1 } from '.'; @@ -7,3 +7,9 @@ export const getCartItems = async () => { return cartItems.data as CartResponse; }; + +export const getCartCount = async () => { + const cartCount = await apiV1.get(`/cart/itemCount`); + + return cartCount.data as CartCountResponse; +};