import { axiosClient } from '../../../api/axiosClient'
import type { RolDto } from './types'

export async function getRol(codigo: string): Promise<RolDto> {
  const response = await axiosClient.get<RolDto>(`/api/v1/roles/${encodeURIComponent(codigo)}`)
  return response.data
}
