import { axiosClient } from '@/api/axiosClient'
import type { AddProductPriceRequest, AddProductPriceResponse } from '../types'

export async function addProductPrice(
  productId: number,
  payload: AddProductPriceRequest,
): Promise<AddProductPriceResponse> {
  const res = await axiosClient.post<AddProductPriceResponse>(
    `/api/v1/admin/products/${productId}/prices`,
    payload,
  )
  return res.data
}
