123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248 |
- /**
- * 统一返回格式
- */
- export interface Output {
- status: number;
- error?: any;
- data?: any;
- }
- /**
- * 发起商家转账零钱
- */
- export declare namespace BatchesTransfer {
- interface TransferDetailList {
- /** 商家明细单号 */
- out_detail_no: string;
- /** 转账金额 */
- transfer_amount: number;
- /** 转账备注 */
- transfer_remark: string;
- /** 用户在直连商户应用下的用户标示 */
- openid: string;
- /** 收款用户姓名 */
- user_name?: string;
- }
- /**
- * 发起商家转账API 请求参数
- */
- interface Input {
- /** 直连商户的appid -不传 默认使用初始化数据 */
- appid?: string;
- /** 商家批次单号 */
- out_batch_no: string;
- /** 批次名称 */
- batch_name: string;
- /** 批次备注 */
- batch_remark: string;
- /** 转账总金额 */
- total_amount: number;
- /** 转账总笔数 */
- total_num: number;
- /** 转账明细列表 */
- transfer_detail_list: TransferDetailList[];
- /** 微信平台证书序列号-Wechatpay-Serial(当有敏感信息加密时,需要当前参数) */
- wx_serial_no?: string;
- }
- interface DataOutput {
- out_batch_no: string;
- batch_id: string;
- create_time: Date;
- }
- /**
- * 发起商家转账API 返回参数
- */
- interface IOutput extends Output {
- data?: DataOutput;
- }
- /**
- * 转账批次单
- */
- interface QueryTransferBatch {
- /** 微信支付分配的商户号 */
- mchid: string;
- /** 商户系统内部的商家批次单号,在商户系统内部唯一 */
- out_batch_no: string;
- /** 微信批次单号,微信商家转账系统返回的唯一标识 */
- batch_id: string;
- /** 申请商户号的appid或商户号绑定的appid(企业号corpid即为此appid) */
- appid: string;
- /** 批次状态 */
- batch_status: string;
- /** 批次类型 */
- batch_type: string;
- /** 该笔批量转账的名称 */
- batch_name: string;
- /** 转账说明,UTF8编码,最多允许32个字符 */
- batch_remark: string;
- /** 批次关闭原因 */
- close_reason?: string;
- /** 转账总金额 */
- total_amount: number;
- /** 转账总笔数 */
- total_num: number;
- /** 批次创建时间 */
- create_time?: Date;
- /** 批次更新时间 */
- update_time?: Date;
- /** 转账成功金额 */
- success_amount?: number;
- /** 转账成功笔数 */
- success_num?: number;
- /** 转账失败金额 */
- fail_amount?: number;
- /** 转账失败笔数 */
- fail_num?: number;
- }
- /**
- * 转账明细单列表
- */
- interface QueryTransferDetailList {
- /** 微信明细单号 */
- detail_id: string;
- /** 商家明细单号 */
- out_detail_no: string;
- /** 明细状态 */
- detail_status: string;
- }
- /**
- * 商家批次单号查询批次单API
- */
- namespace QueryBatchesTransferList {
- /**
- * 商家批次单号查询参数
- */
- interface Input {
- /**商户系统内部的商家批次单号,要求此参数只能由数字、大小写字母组成,在商户系统内部唯一 */
- out_batch_no: string;
- /**商户可选择是否查询指定状态的转账明细单,当转账批次单状态为“FINISHED”(已完成)时,才会返回满足条件的转账明细单 */
- need_query_detail: boolean;
- /**该次请求资源(转账明细单)的起始位置,从0开始,默认值为0 */
- offset?: number;
- /**该次请求可返回的最大资源(转账明细单)条数,最小20条,最大100条,不传则默认20条。不足20条按实际条数返回 */
- limit?: number;
- /**查询指定状态的转账明细单,当need_query_detail为true时,该字段必填 */
- detail_status?: 'ALL' | 'SUCCESS' | 'FAIL';
- }
- interface IOutput extends Output {
- data?: {
- limit: number;
- offset: number;
- transfer_batch: QueryTransferBatch;
- transfer_detail_list: QueryTransferDetailList[];
- };
- }
- }
- /**
- * 微信批次单号查询批次单API
- */
- namespace QueryBatchesTransferByWx {
- interface Input {
- /** 微信批次单号,微信商家转账系统返回的唯一标识 */
- batch_id: string;
- /**商户可选择是否查询指定状态的转账明细单,当转账批次单状态为“FINISHED”(已完成)时,才会返回满足条件的转账明细单 */
- need_query_detail: boolean;
- /**该次请求资源(转账明细单)的起始位置,从0开始,默认值为0 */
- offset?: number;
- /**该次请求可返回的最大资源(转账明细单)条数,最小20条,最大100条,不传则默认20条。不足20条按实际条数返回 */
- limit?: number;
- /**查询指定状态的转账明细单,当need_query_detail为true时,该字段必填 */
- detail_status?: 'ALL' | 'SUCCESS' | 'FAIL';
- }
- interface IOutput extends Output {
- data?: {
- limit: number;
- offset: number;
- transfer_batch: QueryTransferBatch;
- transfer_detail_list: QueryTransferDetailList[];
- };
- }
- }
- /**
- * 微信明细单号查询明细单API
- */
- namespace QueryBatchesTransferDetailByWx {
- interface Input {
- /** 微信批次单号 */
- batch_id: string;
- /** 微信明细单号 */
- detail_id: string;
- }
- interface DetailOutput {
- /** 商户号 */
- mchid: string;
- /** 商家批次单号 */
- out_batch_no: string;
- /** 微信批次单号 */
- batch_id: string;
- /** 直连商户的appid */
- appid: string;
- /** 商家明细单号 */
- out_detail_no: string;
- /** 微信明细单号 */
- detail_id: string;
- /** 明细状态 */
- detail_status: string;
- /** 转账金额 */
- transfer_amount: number;
- /** 转账备注 */
- transfer_remark: string;
- /** 明细失败原因 */
- fail_reason?: string;
- /** 用户在直连商户应用下的用户标示 */
- openid: string;
- /** 收款用户姓名 */
- user_name?: string;
- /** 转账发起时间 */
- initiate_time: Date;
- /** 明细更新时间 */
- update_time: Date;
- }
- interface IOutput extends Output {
- data?: DetailOutput;
- }
- }
- /**
- * 商家明细单号查询明细单API
- */
- namespace QueryBatchesTransferDetail {
- interface Input {
- /** 商家明细单号 */
- out_detail_no: string;
- /** 商家批次单号 */
- out_batch_no: string;
- }
- interface DetailOutput {
- /** 商户号 */
- mchid: string;
- /** 商家批次单号 */
- out_batch_no: string;
- /** 微信批次单号 */
- batch_id: string;
- /** 直连商户的appid */
- appid: string;
- /** 商家明细单号 */
- out_detail_no: string;
- /** 微信明细单号 */
- detail_id: string;
- /** 明细状态 */
- detail_status: string;
- /** 转账金额 */
- transfer_amount: number;
- /** 转账备注 */
- transfer_remark: string;
- /** 明细失败原因 */
- fail_reason?: string;
- /** 用户在直连商户应用下的用户标示 */
- openid: string;
- /** 收款用户姓名 */
- user_name?: string;
- /** 转账发起时间 */
- initiate_time: Date;
- /** 明细更新时间 */
- update_time: Date;
- }
- interface IOutput extends Output {
- data?: DetailOutput;
- }
- }
- }
|