import request, { newService } from '/@/utils/request';

//获取账号列表
export function getaccountList(data: object) {
	return newService({
		url: '/customer-server/customer/service/account/list',
		method: 'get',
		params: data,
	});
}

//添加客服账号
export function addAccount(data: object) {
	return newService({
		url: '/customer-server/customer/service/account/add',
		method: 'post',
		data: data,
	});
}

//禁用账号
export function updatestate(data: object) {
	return newService({
		url: '/customer-server/customer/service/account/toggleStatus',
		method: 'post',
		data: data,
	});
}

//更新账号
export function updateAccount(data: object) {
	return newService({
		url: '/customer-server/customer/service/account/update',
		method: 'post',
		data: data,
	});
}

//获取RAGFlow配置（提示词）
export function getRAGFlowConfig(params: object) {
	return newService({
		url: '/customer-server/ragflow/config/get',
		method: 'get',
		params: params,
	});
}

//更新提示词
export function updatePrompt(data: object) {
	return newService({
		url: '/customer-server/ragflow/config/updatePrompt',
		method: 'post',
		data: data,
	});
}
