This endpoint is used to send a print job to a specific printer via Sunmi Cloud for printing a receipt. The receipt content must be in ESC/POS commands.
{
"sn": "string",
"content": "string",
}
{
"code": 1,
"msg": "success",
"data": {
"trade_no": "1728207421540789905"
}
}
This endpoint is used to send a voice message to a printer connected via Sunmi Cloud. The printer will play the voice message upon receiving the command. This can be used for alerts or notifications such as order confirmations.
{
"sn": "string",
"media_url": "string"
}
{
"code": 1,
"msg": "success",
"data": {
"trade_no": "1728601553951206470"
}
}
This endpoint is used to retrieve the current status of a specific print job that was sent to a printer via Sunmi Cloud. It returns details about whether the print job is still processing, completed, or has encountered an error.
{
"trade_no": "string"
}
{
"code": 1,
"msg": "success",
"data": {
"sn": "N4113227P00012",
"is_print": 1,
"print_time": 1728601558
}
}
This endpoint is used to clear all ongoing or pending print jobs on a specific printer connected via Sunmi Cloud. When called, the printer's job queue will be cleared, and any unfinished print jobs will be canceled.
{
"sn": "string"
}
{
"code": 1,
"msg": "success",
"data": {
"trade_no": "1728601553951206470"
}
}
This endpoint is used to open the cash drawer connected to a specific printer via Sunmi Cloud. When called, the drawer will trigger the open mechanism based on the provided parameters.
{
"sn": "string"
}
{
"code": 1,
"msg": "success",
"data": {
"trade_no": "1728601553951206470"
}
}
This endpoint is used to send a simple test print job to a printer connected via Sunmi Cloud. The printer will print a basic test message to confirm its operation and connection status.
{
"sn": "string"
}
{
"code": 1,
"msg": "success",
"data": {
"trade_no": "1728601553951206470"
}
}