package com.red.circle.other.inner.endpoint.user.user.api;

import com.red.circle.framework.dto.ResultResponse;
import java.util.Set;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 请求黑名单.
 *
 * @author lisizhe on 2023/8/18
 */
public interface RequestBlacklistClientApi {

  String API_PREFIX = "/request-black/client";

  @GetMapping("/addIp")
  ResultResponse<Void> addIp(@RequestParam("ip") String ip);

  @GetMapping("/addPhoneModel")
  ResultResponse<Void> addPhoneModel(@RequestParam("phoneModel") String phoneModel);

  @GetMapping("/delKey")
  ResultResponse<Void> delKey(@RequestParam("key") String key);

  @GetMapping("/matchIpOrPhoneModel")
  ResultResponse<Boolean> matchIpOrPhoneModel(@RequestParam("ip") String ip,
      @RequestParam("phoneModel") String phoneModel);

  @GetMapping("/getKeys")
  ResultResponse<Set<String>> getKeys();
}
