
import request from '@/utils/request'



export const getAgents = (params) => {
    return request({
        url: `api/agents`,
        method: 'get',
        params
    })
}

export const addRobot = (data) => {
    return request({
        url: `api/agent`,
        method: 'post',
        data
    })
}

export const deleteRobot = (id) => {
    return request({
        url: `api/agent/${id}`,
        method: 'delete',
    })
}
export const editRobot = (id, data) => {
    return request({
        url: `api/agent/${id}`,
        method: 'put',
        data
    })
}
export const agentGroups = (params) => {
    return request({
        url: `api/agent/groups`,
        method: 'get',
        params
    })
}

export const agentContacts = (params) => {
    return request({
        url: `api/agent/contacts`,
        method: 'get',
        params
    })
}

export const agentLogs = (params) => {
    return request({
        url: `api/agent/logs`,
        method: 'get',
        params
    })
}