package com.yd.csf.feign.client.csfclientuser;

import com.yd.common.result.Result;
import com.yd.csf.feign.fallback.csfclientuser.ApiCsfClientUserFeignFallbackFactory;
import com.yd.csf.feign.request.csfclientuser.ApiCsfClientUserAddRequest;
import com.yd.csf.feign.request.csfclientuser.ApiCsfClientUserPageRequest;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.validation.annotation.Validated;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

/**
 * 香港保险服务-CSF客户端用户信息接口Feign客户端
 */
@FeignClient(name = "yd-csf-api", fallbackFactory = ApiCsfClientUserFeignFallbackFactory.class)
public interface ApiCsfClientUserFeignClient {

    /**
     * 分页查询-人员信息
     * @param request
     * @return
     */
    @PostMapping("/page")
    Result page(@Validated @RequestBody ApiCsfClientUserPageRequest request);

    /**
     * 新增-人员信息
     * @param request
     * @return
     */
    @PostMapping("/add")
    Result add(@Validated @RequestBody ApiCsfClientUserAddRequest request);
}
