package com.njcn.cssystem.api;

import com.njcn.common.pojo.constant.ServerInfo;
import com.njcn.common.pojo.response.HttpResult;
import com.njcn.cssystem.api.fallback.MsgSendFeignClientFallbackFactory;
import com.njcn.cssystem.pojo.param.MsgSendParam;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * @author xy
 */
@FeignClient(value = ServerInfo.CS_SYSTEM_BOOT, path = "/send", fallbackFactory = MsgSendFeignClientFallbackFactory.class,contextId = "send")
public interface MsgSendFeignClient {

    @PostMapping("/appMsgSend")
    @ApiOperation("app消息推送")
    HttpResult<Boolean> appMsgSend(@RequestBody MsgSendParam param);

    @PostMapping("/smsMsgSend")
    @ApiOperation("短信消息推送")
    HttpResult<Boolean> smsMsgSend(@RequestBody MsgSendParam param);

}
