export interface Params { mode: number; content: string; host?: string; mac?: string; } /** * * @name oncePrint * @title 单次打印 * @description 目前仅支持斑马打印机。打印完毕即断开与打印机的连接 * @param {number} mode - 连接模式, 0:通过蓝牙连接 | 1:通过wifi连接 * @param {string} content - 打印内容,如果为CPCL语言,换行结尾必须加上\n * @param {string} [host] - 通过wifi打印的打印机host地址(ip + 端口) * @param {string} [mac] - 通过蓝牙打印的打印机mac地址 * @return {string} code - 200:成功 | 404:失败 * @return {string} msg - 响应信息 * @return {unknown} data - 响应数据 * @since 3.7.0 * @device Android * @fragment featch(params) { return suplink.oncePrint(params) } * @example * import { oncePrint } from '@suplink/jssdk'; * * oncePrint({ mode: 0, content: '123', host: '127.0.0.1:22' }).then((res) => console.log(res)) */ export default function oncePrint(params: Params): Promise>;