AuthClient.java
747 Bytes
package com.viontech.fanxing.forward;
import com.alibaba.fastjson.JSONObject;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.http.MediaType;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestHeader;
import java.util.Map;
/**
* .
*
* @author 谢明辉
* @date 2021/9/29
*/
@FeignClient(name = "auth", url = "${vion.auth-path}")
public interface AuthClient {
@PostMapping(value = "/auth_serv/api/v1/auth/authorize", produces = MediaType.APPLICATION_JSON_VALUE)
JSONObject checkToken(@RequestHeader("authorization") String token, @RequestBody Map<String, Object> data);
}