package com.seer.teach.user.api;

import com.seer.teach.user.api.dto.UserRelationDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

@FeignClient(name = ApiConstants.SERVER_NAME, contextId = "userRelationServiceApi", path = "/seer/user/internal")
public interface UserRelationServiceApi {

    /**
     * 保存用户关系
     *
     * @param userRelationDTO 用户关系信息
     * @return 保存结果
     */
    @PostMapping("/save-relation")
    boolean saveUserRelation(@RequestBody UserRelationDTO userRelationDTO);

    /**
     * 删除用户关系
     *
     * @param userRelationDTO 用户关系信息
     * @return 删除结果
     */
    @DeleteMapping("/delete")
    boolean deleteUserRelation(@RequestBody UserRelationDTO userRelationDTO);
}