package infrastructure.client.userlogin.api;

import com.banesco.common.domain.model.BaseResponse;
import infrastructure.client.userlogin.dto.request.UserLoginRequest;
import infrastructure.client.userlogin.dto.response.UserLoginResponse;
import infrastructure.interceptor.LoggingFilter;
import jakarta.ws.rs.HeaderParam;
import jakarta.ws.rs.POST;
import org.eclipse.microprofile.rest.client.annotation.ClientHeaderParam;
import org.eclipse.microprofile.rest.client.annotation.RegisterProvider;
import org.eclipse.microprofile.rest.client.inject.RegisterRestClient;

@RegisterRestClient(configKey = "user-login")
@RegisterProvider(LoggingFilter.class)
public interface UserLoginClient {
    @POST
    @ClientHeaderParam(name = "appId", value = "${app.appId}")
    BaseResponse<UserLoginResponse> getUserLogin(
            @HeaderParam("requestId") String requestId,
            UserLoginRequest userLoginRequest
    );
}