package com.jwipc.contract.constant;

import com.dtflys.forest.annotation.BackendClient;
import com.dtflys.forest.annotation.Header;
import com.dtflys.forest.annotation.JSONBody;
import com.dtflys.forest.annotation.Post;
import com.jwipc.api.dto.ApiResult;
import com.jwipc.api.dto.SubjectDTO;
import com.jwipc.log.annotation.ApiOperateLog;
import com.jwipc.log.constant.ApiDirection;
import com.jwipc.log.constant.ThirdSysType;

import java.util.Map;

/**
 * <p> </p>
 *
 * @author ZhangJie
 * @version 1.0
 * @since JDK 1.8
 */
public interface ContractSignClient {

    @BackendClient(cache = false)
    @Post(value = "#{sys.esign.serverip}/esign-signs/v1/signFlow/createAndStart",
            contentEncoding = "UTF-8",
            dataType = "json",
            contentType = "application/json", charset = "UTF-8")
    @ApiOperateLog(code = "sendSign", name = "E签宝一步发起签署", direction = ApiDirection.SRM_TO_OTHER,
            thirdSysType = ThirdSysType.OA)
    ApiResult sendSign(@Header Map<String, String> headerMap, @JSONBody SubjectDTO subjectDTO);

}
