package com.xindazhou.vehicle.api;

import com.xindazhou.framework.common.pojo.CommonResult;
import com.xindazhou.vehicle.api.dto.status.VehicleStatusRespDTO;
import com.xindazhou.vehicle.enums.ApiConstants;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.Parameter;
import io.swagger.v3.oas.annotations.tags.Tag;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

/**
 * 车辆状态 API
 *
 * @author xindazhou
 */
@FeignClient(name = ApiConstants.NAME)
@Tag(name = "RPC 服务 - 车辆状态")
public interface VehicleStatusApi {

    String PREFIX = "/rpc-api/vehicle/status";

    @GetMapping(PREFIX + "/get")
    @Operation(summary = "获取车辆状态")
    @Parameter(name = "vehicleId", description = "车辆编号", required = true, example = "1")
    CommonResult<VehicleStatusRespDTO> getVehicleStatus(@RequestParam("vehicleId") Long vehicleId);

}

