import { IBaseResponse } from '@/@core/types/api'
import { useCustomMutation } from '@/hooks/api'
import { request } from '@/utils'
import { SEND_PASS_URL } from '.'
/* import { ISendPassword } from '@/types/data/password'
 */
export const SEND_CODE_QUERY_LAST = 'send-password-final'

export const useSendPassword = () => {
  const createPlanMutation = useCustomMutation<any, IBaseResponse<any>>([SEND_CODE_QUERY_LAST], data => {
    return request<IBaseResponse<any>, any>({
      url: `${[...SEND_PASS_URL]}`,
      method: 'POST',
      data
    })
  })

  return createPlanMutation
}
