"use strict";
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    var desc = Object.getOwnPropertyDescriptor(m, k);
    if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
      desc = { enumerable: true, get: function() { return m[k]; } };
    }
    Object.defineProperty(o, k2, desc);
}) : (function(o, m, k, k2) {
    if (k2 === undefined) k2 = k;
    o[k2] = m[k];
}));
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
    Object.defineProperty(o, "default", { enumerable: true, value: v });
}) : function(o, v) {
    o["default"] = v;
});
var __importStar = (this && this.__importStar) || (function () {
    var ownKeys = function(o) {
        ownKeys = Object.getOwnPropertyNames || function (o) {
            var ar = [];
            for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
            return ar;
        };
        return ownKeys(o);
    };
    return function (mod) {
        if (mod && mod.__esModule) return mod;
        var result = {};
        if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
        __setModuleDefault(result, mod);
        return result;
    };
})();
var __importDefault = (this && this.__importDefault) || function (mod) {
    return (mod && mod.__esModule) ? mod : { "default": mod };
};
Object.defineProperty(exports, "__esModule", { value: true });
exports.GetFileUploadUrlResponse = exports.GetFileUploadUrlResponseBody = exports.GetFileUploadUrlRequest = exports.GetFileUploadUrlHeaders = exports.GetFileInfoResponse = exports.GetFileInfoResponseBody = exports.GetFileInfoHeaders = exports.GetExecuteUrlResponse = exports.GetExecuteUrlResponseBody = exports.GetExecuteUrlRequest = exports.GetExecuteUrlHeaders = exports.GetCorpInfoResponse = exports.GetCorpInfoResponseBody = exports.GetCorpInfoHeaders = exports.GetCorpConsoleResponse = exports.GetCorpConsoleResponseBody = exports.GetCorpConsoleHeaders = exports.GetContractMarginResponse = exports.GetContractMarginResponseBody = exports.GetContractMarginHeaders = exports.GetAuthUrlResponse = exports.GetAuthUrlResponseBody = exports.GetAuthUrlRequest = exports.GetAuthUrlHeaders = exports.GetAttachsApprovalResponse = exports.GetAttachsApprovalResponseBody = exports.GetAttachsApprovalHeaders = exports.CreateProcessResponse = exports.CreateProcessResponseBody = exports.CreateProcessRequest = exports.CreateProcessHeaders = exports.CreateDevelopersResponse = exports.CreateDevelopersResponseBody = exports.CreateDevelopersRequest = exports.CreateDevelopersHeaders = exports.CorpRealnameResponse = exports.CorpRealnameResponseBody = exports.CorpRealnameRequest = exports.CorpRealnameHeaders = exports.ChannelOrdersResponse = exports.ChannelOrdersResponseBody = exports.ChannelOrdersRequest = exports.ChannelOrdersHeaders = exports.CancelCorpAuthResponse = exports.CancelCorpAuthResponseBody = exports.CancelCorpAuthRequest = exports.CancelCorpAuthHeaders = exports.ApprovalListResponse = exports.ApprovalListResponseBody = exports.ApprovalListHeaders = void 0;
exports.ProcessStartRequestSourceInfo = exports.ProcessStartRequestParticipants = exports.ProcessStartRequestFiles = exports.ProcessStartRequestCcs = exports.GetSignDetailResponseBodySigners = exports.GetFlowDocsResponseBodyData = exports.GetFlowDetailResponseBodyLogs = exports.GetAttachsApprovalResponseBodyData = exports.GetAttachsApprovalResponseBodyDataFiles = exports.CreateProcessRequestSourceInfo = exports.CreateProcessRequestParticipants = exports.CreateProcessRequestParticipantsSignPosList = exports.CreateProcessRequestParticipantsSignPosListSignDate = exports.CreateProcessRequestFiles = exports.CreateProcessRequestCcs = exports.ApprovalListResponseBodyData = exports.ApprovalListResponseBodyDataApprovalNodes = exports.UsersRealnameResponse = exports.UsersRealnameResponseBody = exports.UsersRealnameRequest = exports.UsersRealnameHeaders = exports.ResaleOrderResponse = exports.ResaleOrderResponseBody = exports.ResaleOrderRequest = exports.ResaleOrderHeaders = exports.ProcessStartResponse = exports.ProcessStartResponseBody = exports.ProcessStartRequest = exports.ProcessStartHeaders = exports.GetUserInfoResponse = exports.GetUserInfoResponseBody = exports.GetUserInfoHeaders = exports.GetSignDetailResponse = exports.GetSignDetailResponseBody = exports.GetSignDetailHeaders = exports.GetIsvStatusResponse = exports.GetIsvStatusResponseBody = exports.GetIsvStatusHeaders = exports.GetFlowDocsResponse = exports.GetFlowDocsResponseBody = exports.GetFlowDocsHeaders = exports.GetFlowDetailResponse = exports.GetFlowDetailResponseBody = exports.GetFlowDetailHeaders = void 0;
// This file is auto-generated, don't edit it
/**
 */
const tea_util_1 = __importStar(require("@alicloud/tea-util")), $Util = tea_util_1;
const gateway_dingtalk_1 = __importDefault(require("@alicloud/gateway-dingtalk"));
const openapi_client_1 = __importStar(require("@alicloud/openapi-client")), $OpenApi = openapi_client_1;
const openapi_util_1 = __importDefault(require("@alicloud/openapi-util"));
const $tea = __importStar(require("@alicloud/tea-typescript"));
class ApprovalListHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ApprovalListHeaders = ApprovalListHeaders;
class ApprovalListResponseBody extends $tea.Model {
    static names() {
        return {
            data: 'data',
        };
    }
    static types() {
        return {
            data: { 'type': 'array', 'itemType': ApprovalListResponseBodyData },
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ApprovalListResponseBody = ApprovalListResponseBody;
class ApprovalListResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: ApprovalListResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ApprovalListResponse = ApprovalListResponse;
class CancelCorpAuthHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CancelCorpAuthHeaders = CancelCorpAuthHeaders;
class CancelCorpAuthRequest extends $tea.Model {
    static names() {
        return {};
    }
    static types() {
        return {};
    }
    constructor(map) {
        super(map);
    }
}
exports.CancelCorpAuthRequest = CancelCorpAuthRequest;
class CancelCorpAuthResponseBody extends $tea.Model {
    static names() {
        return {
            result: 'result',
        };
    }
    static types() {
        return {
            result: 'boolean',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CancelCorpAuthResponseBody = CancelCorpAuthResponseBody;
class CancelCorpAuthResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: CancelCorpAuthResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CancelCorpAuthResponse = CancelCorpAuthResponse;
class ChannelOrdersHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ChannelOrdersHeaders = ChannelOrdersHeaders;
class ChannelOrdersRequest extends $tea.Model {
    static names() {
        return {
            itemCode: 'itemCode',
            itemName: 'itemName',
            orderCreateTime: 'orderCreateTime',
            orderId: 'orderId',
            payFee: 'payFee',
            quantity: 'quantity',
        };
    }
    static types() {
        return {
            itemCode: 'string',
            itemName: 'string',
            orderCreateTime: 'number',
            orderId: 'string',
            payFee: 'number',
            quantity: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ChannelOrdersRequest = ChannelOrdersRequest;
class ChannelOrdersResponseBody extends $tea.Model {
    static names() {
        return {
            esignOrderId: 'esignOrderId',
        };
    }
    static types() {
        return {
            esignOrderId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ChannelOrdersResponseBody = ChannelOrdersResponseBody;
class ChannelOrdersResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: ChannelOrdersResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ChannelOrdersResponse = ChannelOrdersResponse;
class CorpRealnameHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CorpRealnameHeaders = CorpRealnameHeaders;
class CorpRealnameRequest extends $tea.Model {
    static names() {
        return {
            redirectUrl: 'redirectUrl',
            userId: 'userId',
        };
    }
    static types() {
        return {
            redirectUrl: 'string',
            userId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CorpRealnameRequest = CorpRealnameRequest;
class CorpRealnameResponseBody extends $tea.Model {
    static names() {
        return {
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            taskId: 'taskId',
        };
    }
    static types() {
        return {
            mobileUrl: 'string',
            pcUrl: 'string',
            taskId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CorpRealnameResponseBody = CorpRealnameResponseBody;
class CorpRealnameResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: CorpRealnameResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CorpRealnameResponse = CorpRealnameResponse;
class CreateDevelopersHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateDevelopersHeaders = CreateDevelopersHeaders;
class CreateDevelopersRequest extends $tea.Model {
    static names() {
        return {
            noticeUrl: 'noticeUrl',
        };
    }
    static types() {
        return {
            noticeUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateDevelopersRequest = CreateDevelopersRequest;
class CreateDevelopersResponseBody extends $tea.Model {
    static names() {
        return {
            data: 'data',
        };
    }
    static types() {
        return {
            data: 'boolean',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateDevelopersResponseBody = CreateDevelopersResponseBody;
class CreateDevelopersResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: CreateDevelopersResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateDevelopersResponse = CreateDevelopersResponse;
class CreateProcessHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessHeaders = CreateProcessHeaders;
class CreateProcessRequest extends $tea.Model {
    static names() {
        return {
            ccs: 'ccs',
            files: 'files',
            initiatorUserId: 'initiatorUserId',
            participants: 'participants',
            redirectUrl: 'redirectUrl',
            signEndTime: 'signEndTime',
            sourceInfo: 'sourceInfo',
            taskName: 'taskName',
        };
    }
    static types() {
        return {
            ccs: { 'type': 'array', 'itemType': CreateProcessRequestCcs },
            files: { 'type': 'array', 'itemType': CreateProcessRequestFiles },
            initiatorUserId: 'string',
            participants: { 'type': 'array', 'itemType': CreateProcessRequestParticipants },
            redirectUrl: 'string',
            signEndTime: 'number',
            sourceInfo: CreateProcessRequestSourceInfo,
            taskName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequest = CreateProcessRequest;
class CreateProcessResponseBody extends $tea.Model {
    static names() {
        return {
            taskId: 'taskId',
        };
    }
    static types() {
        return {
            taskId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessResponseBody = CreateProcessResponseBody;
class CreateProcessResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: CreateProcessResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessResponse = CreateProcessResponse;
class GetAttachsApprovalHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            tsignOpenAppId: 'tsignOpenAppId',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            tsignOpenAppId: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAttachsApprovalHeaders = GetAttachsApprovalHeaders;
class GetAttachsApprovalResponseBody extends $tea.Model {
    static names() {
        return {
            data: 'data',
        };
    }
    static types() {
        return {
            data: { 'type': 'array', 'itemType': GetAttachsApprovalResponseBodyData },
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAttachsApprovalResponseBody = GetAttachsApprovalResponseBody;
class GetAttachsApprovalResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetAttachsApprovalResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAttachsApprovalResponse = GetAttachsApprovalResponse;
class GetAuthUrlHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAuthUrlHeaders = GetAuthUrlHeaders;
class GetAuthUrlRequest extends $tea.Model {
    static names() {
        return {
            redirectUrl: 'redirectUrl',
        };
    }
    static types() {
        return {
            redirectUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAuthUrlRequest = GetAuthUrlRequest;
class GetAuthUrlResponseBody extends $tea.Model {
    static names() {
        return {
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            taskId: 'taskId',
        };
    }
    static types() {
        return {
            mobileUrl: 'string',
            pcUrl: 'string',
            taskId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAuthUrlResponseBody = GetAuthUrlResponseBody;
class GetAuthUrlResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetAuthUrlResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAuthUrlResponse = GetAuthUrlResponse;
class GetContractMarginHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetContractMarginHeaders = GetContractMarginHeaders;
class GetContractMarginResponseBody extends $tea.Model {
    static names() {
        return {
            margin: 'margin',
        };
    }
    static types() {
        return {
            margin: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetContractMarginResponseBody = GetContractMarginResponseBody;
class GetContractMarginResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetContractMarginResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetContractMarginResponse = GetContractMarginResponse;
class GetCorpConsoleHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetCorpConsoleHeaders = GetCorpConsoleHeaders;
class GetCorpConsoleResponseBody extends $tea.Model {
    static names() {
        return {
            orgConsoleUrl: 'orgConsoleUrl',
        };
    }
    static types() {
        return {
            orgConsoleUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetCorpConsoleResponseBody = GetCorpConsoleResponseBody;
class GetCorpConsoleResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetCorpConsoleResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetCorpConsoleResponse = GetCorpConsoleResponse;
class GetCorpInfoHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetCorpInfoHeaders = GetCorpInfoHeaders;
class GetCorpInfoResponseBody extends $tea.Model {
    static names() {
        return {
            isRealName: 'isRealName',
            orgRealName: 'orgRealName',
        };
    }
    static types() {
        return {
            isRealName: 'string',
            orgRealName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetCorpInfoResponseBody = GetCorpInfoResponseBody;
class GetCorpInfoResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetCorpInfoResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetCorpInfoResponse = GetCorpInfoResponse;
class GetExecuteUrlHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetExecuteUrlHeaders = GetExecuteUrlHeaders;
class GetExecuteUrlRequest extends $tea.Model {
    static names() {
        return {
            account: 'account',
            signContainer: 'signContainer',
            taskId: 'taskId',
        };
    }
    static types() {
        return {
            account: 'string',
            signContainer: 'number',
            taskId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetExecuteUrlRequest = GetExecuteUrlRequest;
class GetExecuteUrlResponseBody extends $tea.Model {
    static names() {
        return {
            longUrl: 'longUrl',
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            shortUrl: 'shortUrl',
        };
    }
    static types() {
        return {
            longUrl: 'string',
            mobileUrl: 'string',
            pcUrl: 'string',
            shortUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetExecuteUrlResponseBody = GetExecuteUrlResponseBody;
class GetExecuteUrlResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetExecuteUrlResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetExecuteUrlResponse = GetExecuteUrlResponse;
class GetFileInfoHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileInfoHeaders = GetFileInfoHeaders;
class GetFileInfoResponseBody extends $tea.Model {
    static names() {
        return {
            downloadUrl: 'downloadUrl',
            fileId: 'fileId',
            name: 'name',
            pdfTotalPages: 'pdfTotalPages',
            size: 'size',
            status: 'status',
        };
    }
    static types() {
        return {
            downloadUrl: 'string',
            fileId: 'string',
            name: 'string',
            pdfTotalPages: 'number',
            size: 'number',
            status: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileInfoResponseBody = GetFileInfoResponseBody;
class GetFileInfoResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetFileInfoResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileInfoResponse = GetFileInfoResponse;
class GetFileUploadUrlHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileUploadUrlHeaders = GetFileUploadUrlHeaders;
class GetFileUploadUrlRequest extends $tea.Model {
    static names() {
        return {
            contentMd5: 'contentMd5',
            contentType: 'contentType',
            convert2Pdf: 'convert2Pdf',
            fileName: 'fileName',
            fileSize: 'fileSize',
        };
    }
    static types() {
        return {
            contentMd5: 'string',
            contentType: 'string',
            convert2Pdf: 'boolean',
            fileName: 'string',
            fileSize: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileUploadUrlRequest = GetFileUploadUrlRequest;
class GetFileUploadUrlResponseBody extends $tea.Model {
    static names() {
        return {
            fileId: 'fileId',
            uploadUrl: 'uploadUrl',
        };
    }
    static types() {
        return {
            fileId: 'string',
            uploadUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileUploadUrlResponseBody = GetFileUploadUrlResponseBody;
class GetFileUploadUrlResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetFileUploadUrlResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFileUploadUrlResponse = GetFileUploadUrlResponse;
class GetFlowDetailHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDetailHeaders = GetFlowDetailHeaders;
class GetFlowDetailResponseBody extends $tea.Model {
    static names() {
        return {
            businessScene: 'businessScene',
            flowStatus: 'flowStatus',
            initiatorAuthorizedName: 'initiatorAuthorizedName',
            initiatorName: 'initiatorName',
            logs: 'logs',
        };
    }
    static types() {
        return {
            businessScene: 'string',
            flowStatus: 'number',
            initiatorAuthorizedName: 'string',
            initiatorName: 'string',
            logs: { 'type': 'array', 'itemType': GetFlowDetailResponseBodyLogs },
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDetailResponseBody = GetFlowDetailResponseBody;
class GetFlowDetailResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetFlowDetailResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDetailResponse = GetFlowDetailResponse;
class GetFlowDocsHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDocsHeaders = GetFlowDocsHeaders;
class GetFlowDocsResponseBody extends $tea.Model {
    static names() {
        return {
            data: 'data',
        };
    }
    static types() {
        return {
            data: { 'type': 'array', 'itemType': GetFlowDocsResponseBodyData },
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDocsResponseBody = GetFlowDocsResponseBody;
class GetFlowDocsResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetFlowDocsResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDocsResponse = GetFlowDocsResponse;
class GetIsvStatusHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetIsvStatusHeaders = GetIsvStatusHeaders;
class GetIsvStatusResponseBody extends $tea.Model {
    static names() {
        return {
            authStatus: 'authStatus',
            installStatus: 'installStatus',
        };
    }
    static types() {
        return {
            authStatus: 'string',
            installStatus: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetIsvStatusResponseBody = GetIsvStatusResponseBody;
class GetIsvStatusResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetIsvStatusResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetIsvStatusResponse = GetIsvStatusResponse;
class GetSignDetailHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetSignDetailHeaders = GetSignDetailHeaders;
class GetSignDetailResponseBody extends $tea.Model {
    static names() {
        return {
            businessScene: 'businessScene',
            flowStatus: 'flowStatus',
            signers: 'signers',
        };
    }
    static types() {
        return {
            businessScene: 'string',
            flowStatus: 'number',
            signers: { 'type': 'array', 'itemType': GetSignDetailResponseBodySigners },
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetSignDetailResponseBody = GetSignDetailResponseBody;
class GetSignDetailResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetSignDetailResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetSignDetailResponse = GetSignDetailResponse;
class GetUserInfoHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetUserInfoHeaders = GetUserInfoHeaders;
class GetUserInfoResponseBody extends $tea.Model {
    static names() {
        return {
            isRealName: 'isRealName',
            userRealName: 'userRealName',
        };
    }
    static types() {
        return {
            isRealName: 'string',
            userRealName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetUserInfoResponseBody = GetUserInfoResponseBody;
class GetUserInfoResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: GetUserInfoResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetUserInfoResponse = GetUserInfoResponse;
class ProcessStartHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartHeaders = ProcessStartHeaders;
class ProcessStartRequest extends $tea.Model {
    static names() {
        return {
            autoStart: 'autoStart',
            ccs: 'ccs',
            files: 'files',
            initiatorUserId: 'initiatorUserId',
            participants: 'participants',
            redirectUrl: 'redirectUrl',
            sourceInfo: 'sourceInfo',
            taskName: 'taskName',
        };
    }
    static types() {
        return {
            autoStart: 'string',
            ccs: { 'type': 'array', 'itemType': ProcessStartRequestCcs },
            files: { 'type': 'array', 'itemType': ProcessStartRequestFiles },
            initiatorUserId: 'string',
            participants: { 'type': 'array', 'itemType': ProcessStartRequestParticipants },
            redirectUrl: 'string',
            sourceInfo: ProcessStartRequestSourceInfo,
            taskName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartRequest = ProcessStartRequest;
class ProcessStartResponseBody extends $tea.Model {
    static names() {
        return {
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            taskId: 'taskId',
        };
    }
    static types() {
        return {
            mobileUrl: 'string',
            pcUrl: 'string',
            taskId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartResponseBody = ProcessStartResponseBody;
class ProcessStartResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: ProcessStartResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartResponse = ProcessStartResponse;
class ResaleOrderHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ResaleOrderHeaders = ResaleOrderHeaders;
class ResaleOrderRequest extends $tea.Model {
    static names() {
        return {
            orderCreateTime: 'orderCreateTime',
            orderId: 'orderId',
            quantity: 'quantity',
            serviceStartTime: 'serviceStartTime',
            serviceStopTime: 'serviceStopTime',
        };
    }
    static types() {
        return {
            orderCreateTime: 'number',
            orderId: 'string',
            quantity: 'number',
            serviceStartTime: 'number',
            serviceStopTime: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ResaleOrderRequest = ResaleOrderRequest;
class ResaleOrderResponseBody extends $tea.Model {
    static names() {
        return {
            esignOrderId: 'esignOrderId',
        };
    }
    static types() {
        return {
            esignOrderId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ResaleOrderResponseBody = ResaleOrderResponseBody;
class ResaleOrderResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: ResaleOrderResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ResaleOrderResponse = ResaleOrderResponse;
class UsersRealnameHeaders extends $tea.Model {
    static names() {
        return {
            commonHeaders: 'commonHeaders',
            serviceGroup: 'serviceGroup',
            xAcsDingtalkAccessToken: 'x-acs-dingtalk-access-token',
        };
    }
    static types() {
        return {
            commonHeaders: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            serviceGroup: 'string',
            xAcsDingtalkAccessToken: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.UsersRealnameHeaders = UsersRealnameHeaders;
class UsersRealnameRequest extends $tea.Model {
    static names() {
        return {
            redirectUrl: 'redirectUrl',
            userId: 'userId',
        };
    }
    static types() {
        return {
            redirectUrl: 'string',
            userId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.UsersRealnameRequest = UsersRealnameRequest;
class UsersRealnameResponseBody extends $tea.Model {
    static names() {
        return {
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            taskId: 'taskId',
        };
    }
    static types() {
        return {
            mobileUrl: 'string',
            pcUrl: 'string',
            taskId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.UsersRealnameResponseBody = UsersRealnameResponseBody;
class UsersRealnameResponse extends $tea.Model {
    static names() {
        return {
            headers: 'headers',
            statusCode: 'statusCode',
            body: 'body',
        };
    }
    static types() {
        return {
            headers: { 'type': 'map', 'keyType': 'string', 'valueType': 'string' },
            statusCode: 'number',
            body: UsersRealnameResponseBody,
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.UsersRealnameResponse = UsersRealnameResponse;
class ApprovalListResponseBodyDataApprovalNodes extends $tea.Model {
    static names() {
        return {
            approvalTime: 'approvalTime',
            approverName: 'approverName',
            startTime: 'startTime',
            status: 'status',
        };
    }
    static types() {
        return {
            approvalTime: 'string',
            approverName: 'string',
            startTime: 'number',
            status: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ApprovalListResponseBodyDataApprovalNodes = ApprovalListResponseBodyDataApprovalNodes;
class ApprovalListResponseBodyData extends $tea.Model {
    static names() {
        return {
            approvalName: 'approvalName',
            approvalNodes: 'approvalNodes',
            endTime: 'endTime',
            refuseReason: 'refuseReason',
            sealIdImg: 'sealIdImg',
            sponsorAccountName: 'sponsorAccountName',
            startTime: 'startTime',
            status: 'status',
        };
    }
    static types() {
        return {
            approvalName: 'string',
            approvalNodes: { 'type': 'array', 'itemType': ApprovalListResponseBodyDataApprovalNodes },
            endTime: 'number',
            refuseReason: 'string',
            sealIdImg: 'string',
            sponsorAccountName: 'string',
            startTime: 'number',
            status: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ApprovalListResponseBodyData = ApprovalListResponseBodyData;
class CreateProcessRequestCcs extends $tea.Model {
    static names() {
        return {
            account: 'account',
            accountName: 'accountName',
            accountType: 'accountType',
            orgName: 'orgName',
            userId: 'userId',
        };
    }
    static types() {
        return {
            account: 'string',
            accountName: 'string',
            accountType: 'string',
            orgName: 'string',
            userId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequestCcs = CreateProcessRequestCcs;
class CreateProcessRequestFiles extends $tea.Model {
    static names() {
        return {
            fileId: 'fileId',
            fileName: 'fileName',
            fileType: 'fileType',
        };
    }
    static types() {
        return {
            fileId: 'string',
            fileName: 'string',
            fileType: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequestFiles = CreateProcessRequestFiles;
class CreateProcessRequestParticipantsSignPosListSignDate extends $tea.Model {
    static names() {
        return {
            format: 'format',
        };
    }
    static types() {
        return {
            format: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequestParticipantsSignPosListSignDate = CreateProcessRequestParticipantsSignPosListSignDate;
class CreateProcessRequestParticipantsSignPosList extends $tea.Model {
    static names() {
        return {
            fileId: 'fileId',
            isCrossPage: 'isCrossPage',
            needSignDate: 'needSignDate',
            page: 'page',
            signDate: 'signDate',
            signRequirement: 'signRequirement',
            x: 'x',
            y: 'y',
        };
    }
    static types() {
        return {
            fileId: 'string',
            isCrossPage: 'boolean',
            needSignDate: 'boolean',
            page: 'string',
            signDate: CreateProcessRequestParticipantsSignPosListSignDate,
            signRequirement: 'string',
            x: 'number',
            y: 'number',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequestParticipantsSignPosList = CreateProcessRequestParticipantsSignPosList;
class CreateProcessRequestParticipants extends $tea.Model {
    static names() {
        return {
            account: 'account',
            accountName: 'accountName',
            accountType: 'accountType',
            orgName: 'orgName',
            signOrder: 'signOrder',
            signPosList: 'signPosList',
            signRequirements: 'signRequirements',
            userId: 'userId',
        };
    }
    static types() {
        return {
            account: 'string',
            accountName: 'string',
            accountType: 'string',
            orgName: 'string',
            signOrder: 'number',
            signPosList: { 'type': 'array', 'itemType': CreateProcessRequestParticipantsSignPosList },
            signRequirements: 'string',
            userId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequestParticipants = CreateProcessRequestParticipants;
class CreateProcessRequestSourceInfo extends $tea.Model {
    static names() {
        return {
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            showText: 'showText',
        };
    }
    static types() {
        return {
            mobileUrl: 'string',
            pcUrl: 'string',
            showText: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.CreateProcessRequestSourceInfo = CreateProcessRequestSourceInfo;
class GetAttachsApprovalResponseBodyDataFiles extends $tea.Model {
    static names() {
        return {
            fileName: 'fileName',
            originalFileUrl: 'originalFileUrl',
            signFinishFileUrl: 'signFinishFileUrl',
        };
    }
    static types() {
        return {
            fileName: 'string',
            originalFileUrl: 'string',
            signFinishFileUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAttachsApprovalResponseBodyDataFiles = GetAttachsApprovalResponseBodyDataFiles;
class GetAttachsApprovalResponseBodyData extends $tea.Model {
    static names() {
        return {
            files: 'files',
            flowId: 'flowId',
            status: 'status',
        };
    }
    static types() {
        return {
            files: { 'type': 'array', 'itemType': GetAttachsApprovalResponseBodyDataFiles },
            flowId: 'string',
            status: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetAttachsApprovalResponseBodyData = GetAttachsApprovalResponseBodyData;
class GetFlowDetailResponseBodyLogs extends $tea.Model {
    static names() {
        return {
            logType: 'logType',
            operateDescription: 'operateDescription',
            operateTime: 'operateTime',
            operatorAccountName: 'operatorAccountName',
        };
    }
    static types() {
        return {
            logType: 'string',
            operateDescription: 'string',
            operateTime: 'number',
            operatorAccountName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDetailResponseBodyLogs = GetFlowDetailResponseBodyLogs;
class GetFlowDocsResponseBodyData extends $tea.Model {
    static names() {
        return {
            fileId: 'fileId',
            fileName: 'fileName',
            fileUrl: 'fileUrl',
        };
    }
    static types() {
        return {
            fileId: 'string',
            fileName: 'string',
            fileUrl: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetFlowDocsResponseBodyData = GetFlowDocsResponseBodyData;
class GetSignDetailResponseBodySigners extends $tea.Model {
    static names() {
        return {
            signStatus: 'signStatus',
            signerName: 'signerName',
        };
    }
    static types() {
        return {
            signStatus: 'number',
            signerName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.GetSignDetailResponseBodySigners = GetSignDetailResponseBodySigners;
class ProcessStartRequestCcs extends $tea.Model {
    static names() {
        return {
            account: 'account',
            accountName: 'accountName',
            accountType: 'accountType',
            orgName: 'orgName',
            userId: 'userId',
        };
    }
    static types() {
        return {
            account: 'string',
            accountName: 'string',
            accountType: 'string',
            orgName: 'string',
            userId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartRequestCcs = ProcessStartRequestCcs;
class ProcessStartRequestFiles extends $tea.Model {
    static names() {
        return {
            fileId: 'fileId',
            fileName: 'fileName',
        };
    }
    static types() {
        return {
            fileId: 'string',
            fileName: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartRequestFiles = ProcessStartRequestFiles;
class ProcessStartRequestParticipants extends $tea.Model {
    static names() {
        return {
            account: 'account',
            accountName: 'accountName',
            accountType: 'accountType',
            orgName: 'orgName',
            signRequirements: 'signRequirements',
            userId: 'userId',
        };
    }
    static types() {
        return {
            account: 'string',
            accountName: 'string',
            accountType: 'string',
            orgName: 'string',
            signRequirements: 'string',
            userId: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartRequestParticipants = ProcessStartRequestParticipants;
class ProcessStartRequestSourceInfo extends $tea.Model {
    static names() {
        return {
            mobileUrl: 'mobileUrl',
            pcUrl: 'pcUrl',
            showText: 'showText',
        };
    }
    static types() {
        return {
            mobileUrl: 'string',
            pcUrl: 'string',
            showText: 'string',
        };
    }
    constructor(map) {
        super(map);
    }
}
exports.ProcessStartRequestSourceInfo = ProcessStartRequestSourceInfo;
class Client extends openapi_client_1.default {
    constructor(config) {
        super(config);
        let gatewayClient = new gateway_dingtalk_1.default();
        this._spi = gatewayClient;
        this._endpointRule = "";
        if (tea_util_1.default.empty(this._endpoint)) {
            this._endpoint = "api.dingtalk.com";
        }
    }
    /**
     * 获取流程任务用印审批列表
     *
     * @param headers - ApprovalListHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns ApprovalListResponse
     */
    async approvalListWithOptions(taskId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "ApprovalList",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/approvals/${taskId}`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new ApprovalListResponse({}));
    }
    /**
     * 获取流程任务用印审批列表
     * @returns ApprovalListResponse
     */
    async approvalList(taskId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new ApprovalListHeaders({});
        return await this.approvalListWithOptions(taskId, headers, runtime);
    }
    /**
     * 取消企业的授权
     *
     * @param request - CancelCorpAuthRequest
     * @param headers - CancelCorpAuthHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns CancelCorpAuthResponse
     */
    async cancelCorpAuthWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "CancelCorpAuth",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/auths/cancel`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new CancelCorpAuthResponse({}));
    }
    /**
     * 取消企业的授权
     *
     * @param request - CancelCorpAuthRequest
     * @returns CancelCorpAuthResponse
     */
    async cancelCorpAuth(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new CancelCorpAuthHeaders({});
        return await this.cancelCorpAuthWithOptions(request, headers, runtime);
    }
    /**
     * 套餐转售1（分润模式）
     *
     * @param request - ChannelOrdersRequest
     * @param headers - ChannelOrdersHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns ChannelOrdersResponse
     */
    async channelOrdersWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.itemCode)) {
            body["itemCode"] = request.itemCode;
        }
        if (!tea_util_1.default.isUnset(request.itemName)) {
            body["itemName"] = request.itemName;
        }
        if (!tea_util_1.default.isUnset(request.orderCreateTime)) {
            body["orderCreateTime"] = request.orderCreateTime;
        }
        if (!tea_util_1.default.isUnset(request.orderId)) {
            body["orderId"] = request.orderId;
        }
        if (!tea_util_1.default.isUnset(request.payFee)) {
            body["payFee"] = request.payFee;
        }
        if (!tea_util_1.default.isUnset(request.quantity)) {
            body["quantity"] = request.quantity;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "ChannelOrders",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/orders/channel`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new ChannelOrdersResponse({}));
    }
    /**
     * 套餐转售1（分润模式）
     *
     * @param request - ChannelOrdersRequest
     * @returns ChannelOrdersResponse
     */
    async channelOrders(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new ChannelOrdersHeaders({});
        return await this.channelOrdersWithOptions(request, headers, runtime);
    }
    /**
     * 生成企业实名的跳转地址
     *
     * @param request - CorpRealnameRequest
     * @param headers - CorpRealnameHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns CorpRealnameResponse
     */
    async corpRealnameWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.redirectUrl)) {
            body["redirectUrl"] = request.redirectUrl;
        }
        if (!tea_util_1.default.isUnset(request.userId)) {
            body["userId"] = request.userId;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "CorpRealname",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/corps/realnames`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new CorpRealnameResponse({}));
    }
    /**
     * 生成企业实名的跳转地址
     *
     * @param request - CorpRealnameRequest
     * @returns CorpRealnameResponse
     */
    async corpRealname(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new CorpRealnameHeaders({});
        return await this.corpRealnameWithOptions(request, headers, runtime);
    }
    /**
     * 钉钉ISV服务商数据初始化
     *
     * @param request - CreateDevelopersRequest
     * @param headers - CreateDevelopersHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns CreateDevelopersResponse
     */
    async createDevelopersWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.noticeUrl)) {
            body["noticeUrl"] = request.noticeUrl;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "CreateDevelopers",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/developers`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new CreateDevelopersResponse({}));
    }
    /**
     * 钉钉ISV服务商数据初始化
     *
     * @param request - CreateDevelopersRequest
     * @returns CreateDevelopersResponse
     */
    async createDevelopers(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new CreateDevelopersHeaders({});
        return await this.createDevelopersWithOptions(request, headers, runtime);
    }
    /**
     * 通过API发起签署流程
     *
     * @param request - CreateProcessRequest
     * @param headers - CreateProcessHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns CreateProcessResponse
     */
    async createProcessWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.ccs)) {
            body["ccs"] = request.ccs;
        }
        if (!tea_util_1.default.isUnset(request.files)) {
            body["files"] = request.files;
        }
        if (!tea_util_1.default.isUnset(request.initiatorUserId)) {
            body["initiatorUserId"] = request.initiatorUserId;
        }
        if (!tea_util_1.default.isUnset(request.participants)) {
            body["participants"] = request.participants;
        }
        if (!tea_util_1.default.isUnset(request.redirectUrl)) {
            body["redirectUrl"] = request.redirectUrl;
        }
        if (!tea_util_1.default.isUnset(request.signEndTime)) {
            body["signEndTime"] = request.signEndTime;
        }
        if (!tea_util_1.default.isUnset(request.sourceInfo)) {
            body["sourceInfo"] = request.sourceInfo;
        }
        if (!tea_util_1.default.isUnset(request.taskName)) {
            body["taskName"] = request.taskName;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "CreateProcess",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/process/startAtOnce`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new CreateProcessResponse({}));
    }
    /**
     * 通过API发起签署流程
     *
     * @param request - CreateProcessRequest
     * @returns CreateProcessResponse
     */
    async createProcess(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new CreateProcessHeaders({});
        return await this.createProcessWithOptions(request, headers, runtime);
    }
    /**
     * 获取钉钉审批实例-电子附件信息
     *
     * @param headers - GetAttachsApprovalHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetAttachsApprovalResponse
     */
    async getAttachsApprovalWithOptions(instanceId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.tsignOpenAppId)) {
            realHeaders["tsignOpenAppId"] = tea_util_1.default.toJSONString(headers.tsignOpenAppId);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetAttachsApproval",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/dingInstances/${instanceId}/attachments`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetAttachsApprovalResponse({}));
    }
    /**
     * 获取钉钉审批实例-电子附件信息
     * @returns GetAttachsApprovalResponse
     */
    async getAttachsApproval(instanceId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetAttachsApprovalHeaders({});
        return await this.getAttachsApprovalWithOptions(instanceId, headers, runtime);
    }
    /**
     * 生成授权页面地址
     *
     * @param request - GetAuthUrlRequest
     * @param headers - GetAuthUrlHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetAuthUrlResponse
     */
    async getAuthUrlWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.redirectUrl)) {
            body["redirectUrl"] = request.redirectUrl;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "GetAuthUrl",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/auths/urls`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetAuthUrlResponse({}));
    }
    /**
     * 生成授权页面地址
     *
     * @param request - GetAuthUrlRequest
     * @returns GetAuthUrlResponse
     */
    async getAuthUrl(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetAuthUrlHeaders({});
        return await this.getAuthUrlWithOptions(request, headers, runtime);
    }
    /**
     * 查询套餐余量
     *
     * @param headers - GetContractMarginHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetContractMarginResponse
     */
    async getContractMarginWithOptions(headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetContractMargin",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/margins`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetContractMarginResponse({}));
    }
    /**
     * 查询套餐余量
     * @returns GetContractMarginResponse
     */
    async getContractMargin() {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetContractMarginHeaders({});
        return await this.getContractMarginWithOptions(headers, runtime);
    }
    /**
     * 获取企业控制台地址
     *
     * @param headers - GetCorpConsoleHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetCorpConsoleResponse
     */
    async getCorpConsoleWithOptions(headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetCorpConsole",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/corps/consoles`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetCorpConsoleResponse({}));
    }
    /**
     * 获取企业控制台地址
     * @returns GetCorpConsoleResponse
     */
    async getCorpConsole() {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetCorpConsoleHeaders({});
        return await this.getCorpConsoleWithOptions(headers, runtime);
    }
    /**
     * 查询企业信息
     *
     * @param headers - GetCorpInfoHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetCorpInfoResponse
     */
    async getCorpInfoWithOptions(headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetCorpInfo",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/corps/infos`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetCorpInfoResponse({}));
    }
    /**
     * 查询企业信息
     * @returns GetCorpInfoResponse
     */
    async getCorpInfo() {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetCorpInfoHeaders({});
        return await this.getCorpInfoWithOptions(headers, runtime);
    }
    /**
     * 获取签署人签署地址
     *
     * @param request - GetExecuteUrlRequest
     * @param headers - GetExecuteUrlHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetExecuteUrlResponse
     */
    async getExecuteUrlWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.account)) {
            body["account"] = request.account;
        }
        if (!tea_util_1.default.isUnset(request.signContainer)) {
            body["signContainer"] = request.signContainer;
        }
        if (!tea_util_1.default.isUnset(request.taskId)) {
            body["taskId"] = request.taskId;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "GetExecuteUrl",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/process/executeUrls`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetExecuteUrlResponse({}));
    }
    /**
     * 获取签署人签署地址
     *
     * @param request - GetExecuteUrlRequest
     * @returns GetExecuteUrlResponse
     */
    async getExecuteUrl(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetExecuteUrlHeaders({});
        return await this.getExecuteUrlWithOptions(request, headers, runtime);
    }
    /**
     * 获取文件详情
     *
     * @param headers - GetFileInfoHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetFileInfoResponse
     */
    async getFileInfoWithOptions(fileId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetFileInfo",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/files/${fileId}`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetFileInfoResponse({}));
    }
    /**
     * 获取文件详情
     * @returns GetFileInfoResponse
     */
    async getFileInfo(fileId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetFileInfoHeaders({});
        return await this.getFileInfoWithOptions(fileId, headers, runtime);
    }
    /**
     * 获取文件上传地址
     *
     * @param request - GetFileUploadUrlRequest
     * @param headers - GetFileUploadUrlHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetFileUploadUrlResponse
     */
    async getFileUploadUrlWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.contentMd5)) {
            body["contentMd5"] = request.contentMd5;
        }
        if (!tea_util_1.default.isUnset(request.contentType)) {
            body["contentType"] = request.contentType;
        }
        if (!tea_util_1.default.isUnset(request.convert2Pdf)) {
            body["convert2Pdf"] = request.convert2Pdf;
        }
        if (!tea_util_1.default.isUnset(request.fileName)) {
            body["fileName"] = request.fileName;
        }
        if (!tea_util_1.default.isUnset(request.fileSize)) {
            body["fileSize"] = request.fileSize;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "GetFileUploadUrl",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/files/uploadUrls`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetFileUploadUrlResponse({}));
    }
    /**
     * 获取文件上传地址
     *
     * @param request - GetFileUploadUrlRequest
     * @returns GetFileUploadUrlResponse
     */
    async getFileUploadUrl(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetFileUploadUrlHeaders({});
        return await this.getFileUploadUrlWithOptions(request, headers, runtime);
    }
    /**
     * 获取流程详细信息及操作记录
     *
     * @param headers - GetFlowDetailHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetFlowDetailResponse
     */
    async getFlowDetailWithOptions(taskId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetFlowDetail",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/flowTasks/${taskId}`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetFlowDetailResponse({}));
    }
    /**
     * 获取流程详细信息及操作记录
     * @returns GetFlowDetailResponse
     */
    async getFlowDetail(taskId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetFlowDetailHeaders({});
        return await this.getFlowDetailWithOptions(taskId, headers, runtime);
    }
    /**
     * 获取流程任务的所有合同列表，收到签署完成消息后查询
     *
     * @param headers - GetFlowDocsHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetFlowDocsResponse
     */
    async getFlowDocsWithOptions(taskId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetFlowDocs",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/flowTasks/${taskId}/docs`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetFlowDocsResponse({}));
    }
    /**
     * 获取流程任务的所有合同列表，收到签署完成消息后查询
     * @returns GetFlowDocsResponse
     */
    async getFlowDocs(taskId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetFlowDocsHeaders({});
        return await this.getFlowDocsWithOptions(taskId, headers, runtime);
    }
    /**
     * 获取企业的e签宝微应用当前状态
     *
     * @param headers - GetIsvStatusHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetIsvStatusResponse
     */
    async getIsvStatusWithOptions(headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetIsvStatus",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/corps/appStatus`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetIsvStatusResponse({}));
    }
    /**
     * 获取企业的e签宝微应用当前状态
     * @returns GetIsvStatusResponse
     */
    async getIsvStatus() {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetIsvStatusHeaders({});
        return await this.getIsvStatusWithOptions(headers, runtime);
    }
    /**
     * 获取流程签署的详细信息
     *
     * @param headers - GetSignDetailHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetSignDetailResponse
     */
    async getSignDetailWithOptions(taskId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetSignDetail",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/signTasks/${taskId}`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetSignDetailResponse({}));
    }
    /**
     * 获取流程签署的详细信息
     * @returns GetSignDetailResponse
     */
    async getSignDetail(taskId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetSignDetailHeaders({});
        return await this.getSignDetailWithOptions(taskId, headers, runtime);
    }
    /**
     * 查询个人信息
     *
     * @param headers - GetUserInfoHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns GetUserInfoResponse
     */
    async getUserInfoWithOptions(userId, headers, runtime) {
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
        });
        let params = new $OpenApi.Params({
            action: "GetUserInfo",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/users/${userId}`,
            method: "GET",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new GetUserInfoResponse({}));
    }
    /**
     * 查询个人信息
     * @returns GetUserInfoResponse
     */
    async getUserInfo(userId) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new GetUserInfoHeaders({});
        return await this.getUserInfoWithOptions(userId, headers, runtime);
    }
    /**
     * 获取发起签署任务的地址
     *
     * @param request - ProcessStartRequest
     * @param headers - ProcessStartHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns ProcessStartResponse
     */
    async processStartWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.autoStart)) {
            body["autoStart"] = request.autoStart;
        }
        if (!tea_util_1.default.isUnset(request.ccs)) {
            body["ccs"] = request.ccs;
        }
        if (!tea_util_1.default.isUnset(request.files)) {
            body["files"] = request.files;
        }
        if (!tea_util_1.default.isUnset(request.initiatorUserId)) {
            body["initiatorUserId"] = request.initiatorUserId;
        }
        if (!tea_util_1.default.isUnset(request.participants)) {
            body["participants"] = request.participants;
        }
        if (!tea_util_1.default.isUnset(request.redirectUrl)) {
            body["redirectUrl"] = request.redirectUrl;
        }
        if (!tea_util_1.default.isUnset(request.sourceInfo)) {
            body["sourceInfo"] = request.sourceInfo;
        }
        if (!tea_util_1.default.isUnset(request.taskName)) {
            body["taskName"] = request.taskName;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "ProcessStart",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/processes/startUrls`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new ProcessStartResponse({}));
    }
    /**
     * 获取发起签署任务的地址
     *
     * @param request - ProcessStartRequest
     * @returns ProcessStartResponse
     */
    async processStart(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new ProcessStartHeaders({});
        return await this.processStartWithOptions(request, headers, runtime);
    }
    /**
     * 套餐转售2（底价结算模式）
     *
     * @param request - ResaleOrderRequest
     * @param headers - ResaleOrderHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns ResaleOrderResponse
     */
    async resaleOrderWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.orderCreateTime)) {
            body["orderCreateTime"] = request.orderCreateTime;
        }
        if (!tea_util_1.default.isUnset(request.orderId)) {
            body["orderId"] = request.orderId;
        }
        if (!tea_util_1.default.isUnset(request.quantity)) {
            body["quantity"] = request.quantity;
        }
        if (!tea_util_1.default.isUnset(request.serviceStartTime)) {
            body["serviceStartTime"] = request.serviceStartTime;
        }
        if (!tea_util_1.default.isUnset(request.serviceStopTime)) {
            body["serviceStopTime"] = request.serviceStopTime;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "ResaleOrder",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/orders/resale`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new ResaleOrderResponse({}));
    }
    /**
     * 套餐转售2（底价结算模式）
     *
     * @param request - ResaleOrderRequest
     * @returns ResaleOrderResponse
     */
    async resaleOrder(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new ResaleOrderHeaders({});
        return await this.resaleOrderWithOptions(request, headers, runtime);
    }
    /**
     * 获取跳转到个人实名的地址
     *
     * @param request - UsersRealnameRequest
     * @param headers - UsersRealnameHeaders
     * @param runtime - runtime options for this request RuntimeOptions
     * @returns UsersRealnameResponse
     */
    async usersRealnameWithOptions(request, headers, runtime) {
        tea_util_1.default.validateModel(request);
        let body = {};
        if (!tea_util_1.default.isUnset(request.redirectUrl)) {
            body["redirectUrl"] = request.redirectUrl;
        }
        if (!tea_util_1.default.isUnset(request.userId)) {
            body["userId"] = request.userId;
        }
        let realHeaders = {};
        if (!tea_util_1.default.isUnset(headers.commonHeaders)) {
            realHeaders = headers.commonHeaders;
        }
        if (!tea_util_1.default.isUnset(headers.serviceGroup)) {
            realHeaders["serviceGroup"] = tea_util_1.default.toJSONString(headers.serviceGroup);
        }
        if (!tea_util_1.default.isUnset(headers.xAcsDingtalkAccessToken)) {
            realHeaders["x-acs-dingtalk-access-token"] = tea_util_1.default.toJSONString(headers.xAcsDingtalkAccessToken);
        }
        let req = new $OpenApi.OpenApiRequest({
            headers: realHeaders,
            body: openapi_util_1.default.parseToMap(body),
        });
        let params = new $OpenApi.Params({
            action: "UsersRealname",
            version: "esign_2.0",
            protocol: "HTTP",
            pathname: `/v2.0/esign/users/realnames`,
            method: "POST",
            authType: "AK",
            style: "ROA",
            reqBodyType: "json",
            bodyType: "json",
        });
        return $tea.cast(await this.execute(params, req, runtime), new UsersRealnameResponse({}));
    }
    /**
     * 获取跳转到个人实名的地址
     *
     * @param request - UsersRealnameRequest
     * @returns UsersRealnameResponse
     */
    async usersRealname(request) {
        let runtime = new $Util.RuntimeOptions({});
        let headers = new UsersRealnameHeaders({});
        return await this.usersRealnameWithOptions(request, headers, runtime);
    }
}
exports.default = Client;
//# sourceMappingURL=client.js.map