package com.xinelu.manage.controller.yaiobs;

import com.alibaba.fastjson2.JSONObject;
import com.aliyuncs.exceptions.ClientException;
import com.xinelu.manage.dto.aiob.DutyCallbackDto;
import com.xinelu.manage.service.yzaiobs.IYZAIOBSService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import javax.annotation.Resource;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @description: 曜智·智能外呼平台控制器
 * @author: haown
 * @create: 2025-12-29 10:08
 **/
@Api(tags = "曜智·智能外呼平台控制器")
@RestController
@RequestMapping("/yzapi")
public class YZAIOBSController {

	@Resource
	private IYZAIOBSService iyzaiobsService;

	/**
	 * @description 任务回调
	 * @param dutyCallbackDto: 回调数据
	 * @return null
	 * @Author haown
	 * @Date 2024-8-29 11:15
	 */
	@ApiOperation("任务回调")
	@PostMapping("/taskCallBack")
	public JSONObject taskCallBack(@RequestBody DutyCallbackDto dutyCallbackDto) throws ClientException {

		return iyzaiobsService.taskCallBack(dutyCallbackDto);
	}
}
