package com.jeequan.jeepay.core.interfaces.paychannel;

import com.alibaba.fastjson.JSONObject;
import com.jeequan.jeepay.core.constants.CS;
import com.jeequan.jeepay.core.entity.MchApplyment;
import com.jeequan.jeepay.core.model.applyment.PaywayFee;
import com.jeequan.jeepay.core.model.params.IsvParams;
import com.jeequan.jeepay.core.model.rqrs.mch.ChannelMchRq;
import com.jeequan.jeepay.core.model.rqrs.msg.ChannelRetMsg;
import com.jeequan.jeepay.core.model.rqrs.settle.ChannelSettleRq;
import org.apache.commons.lang3.tuple.MutablePair;

import java.util.List;
import java.util.Map;

/**
 * TODO
 * 商户操作接口定义 用于处理商户在通道方的一些接口定义 例如 新增appid 支付授权目录
 * @author crystal
 * @date 2023/12/4 10:34
 */
public interface IMchApiService<T extends IsvParams> {

    /** 获取到接口code **/
    String getIfCode();

    /**
     * 前置参数校验
     * @return
     */
    boolean preCheck();

    /**
     * appid和支付授权目录相关操作
     * @param applyment
     * @param mchRq
     * @return
     */
    ChannelRetMsg appidAndPath(MchApplyment applyment, ChannelMchRq mchRq);

    /**
     * 查询商户结算记录
     * @param settleRq
     * @return
     */
    List<JSONObject> querySettleInfo(ChannelSettleRq settleRq, String isvNo, T isvParams);

}
