Control Text Content
Deprecated legacy endpoint
Status: Deprecated. The legacy endpoint https://dot.mindreset.tech/api/open/text currently forwards requests to the new API.
This compatibility behavior may be removed in a future release. No removal date is confirmed.
To keep your integration compatible:
- Update the request URL to the new endpoint:
/api/authV2/open/device/:deviceId/text - Send parameters according to this document (e.g.
refreshNow/taskAlias/title/message/signature/icon/link/taskKey/styles) - If you rely on legacy response payloads or error codes, adapt your integration to the new API responses
Quick Guide
Prerequisites
- Make sure you have retrieved and saved your API key in the Dot. App;
- Make sure you own at least one device and have obtained its device serial number;
- Make sure your device is connected to power;
- Make sure your device is connected to the network;
- Make sure you've added the Text API content to the device Loop task from the Content Studio in the Dot. App.
What Text API is for
Text API turns reminders, notes, signatures, and small icons into a readable device card. Use it for automation messages, lightweight notifications, daily excerpts, or any short text you want to see on the device.
About API display timing
The API's immediate display capability depends on whether the device is currently online. If the device is running on battery and asleep, the content is saved to the server first and displayed after the device wakes automatically. Read Timing to learn more.
About icon input
The icon field is optional. If you send an icon, it must be PNG Base64 data or a full online http(s) image URL. PNG Base64 may be bare Base64 or include the data:image/png;base64, prefix; the decoded payload must be no larger than 1MB. A 40px×40px icon is recommended. Remote icon URLs must be anonymously accessible, require no authentication or special Referer, be no longer than 2048 characters, return a response body no larger than 3MB, and return image/* content directly.
Test icon URLs for debugging
The following URLs are currently anonymously accessible and return image content that can be used for the Text API icon field:
https://placehold.co/40x40/pnghttps://httpbin.org/image/png
If you want to verify your own icon URL first, run:
curl -I 'https://your-icon-url'In most cases, you should confirm at least:
- The HTTP status code is
200 - The
Content-Typeisimage/*, such asimage/pngorimage/jpeg
The API rate limit is 10 requests per second. With the API, you can control device behavior and responses more flexibly.
Placeholders wrapped in ‘{{variable}}’ indicate values you must replace. Fill them with your actual values and remove the ‘{{}}’ braces.
Request Examples
/api/authV2/open/device/:deviceId/text1// Generating...Response Example
{
"message": "Device ABCD1234ABCD text API content switched."
}Reference Usage
- Simple text without immediate display
curl -X POST \
https://dot.mindreset.tech/api/authV2/open/device/{{deviceId}}/text \
-H 'Authorization: Bearer dot_app_UlSpzXNEXhYZIAFakHLCkMVVBLbsBIWxaRMVaJZGUOYKhDoDRZwLLvLujAIwQxbY' \
-H 'Content-Type: application/json' \
-d '{
"refreshNow": false,
"title": "evnydd0sf",
"message": "我能吞下玻璃而不伤身体"
}'- Complex text and display immediately
curl -X POST \
https://dot.mindreset.tech/api/authV2/open/device/{{deviceId}}/text \
-H 'Authorization: Bearer dot_app_UlSpzXNEXhYZIAFakHLCkMVVBLbsBIWxaRMVaJZGUOYKhDoDRZwLLvLujAIwQxbY' \
-H 'Content-Type: application/json' \
-d '{
"title": "验证码小助手",
"message": "一个来自「少数派」的验证码\n205112",
"signature": "2025年8月4日 19:58",
"styles": {
"title": { "fontFamily": "ChillDuanSans", "fontSize": 30, "fontWeight": 700 },
"message": { "fontFamily": "FusionPixel12", "fontSize": 22, "lineHeight": 1.25 },
"signature": { "fontFamily": "ChillDuanSans", "fontSize": 16 }
}
}'- Complex text with icon and link, display immediately
curl -X POST \
https://dot.mindreset.tech/api/authV2/open/device/{{deviceId}}/text \
-H 'Authorization: Bearer dot_app_UlSpzXNEXhYZIAFakHLCkMVVBLbsBIWxaRMVaJZGUOYKhDoDRZwLLvLujAIwQxbY' \
-H 'Content-Type: application/json' \
-d '{
"title": "每日健康",
"message": "消耗卡路里:702千卡\n今日步数:4183步\n站立时间:62分钟",
"signature": "2025年8月4日 20:16",
"icon": "{{PNG Base64 icon data (max 1MB) or http(s) image URL}}",
"link": "x-apple-health://"
}'- Highly customized text or graphics
Refer to the Image API section on text-as-image usage
Line Breaks and Tabs
Text API preserves line breaks and tabs in message.
- Use
\nfor a new line and\tfor a tab in the JSON request body. - If your JSON is embedded inside another string literal, such as shell, JavaScript, Python, templates, or tool configs, you often need to write
\\nand\\tin the outer string so the final JSON still contains\nand\t. - If you want the device to literally display the characters
\nor\t, make the final JSON payload contain\\nor\\t.
{ "message": "Line 1\n\tIndented line 2" }
{ "message": "Show literal \\n and \\t" }Troubleshooting
Endpoint
/api/authV2/open/device/:deviceId/text
Method
POST
Request Schema
Prop
Type
Default
true
Supported Fonts
Use the exact fontFamily value in styles.*.fontFamily.
| fontFamily | Notes |
|---|---|
ChillDuanSans | General CJK sans |
ChillKSans | General sans |
ChillOrganic | Organic display style |
ChillRoundF | Rounded display style |
ChillRoundGothic | Bold rounded gothic |
Cusong16 | 16px pixel Song style |
DotGothic16 | 16px pixel gothic |
FusionPixel8 | 8px pixel font |
FusionPixel10 | 10px pixel font |
FusionPixel12 | 12px pixel font |
Liusong24 | 24px pixel Song style |
LogoSCUnboundedSans | Display sans |
MaokenYingBiKaiShuJ0.09 | Handwriting display style |
PlayfairDisplay | Latin serif display |
Quan8 | 8px pixel font |
Unifont16 | 16px broad Unicode coverage |
UnifontExMono16 | 16px mono Unicode coverage |
XiaoyaPixel12 | 12px pixel style |
Zihunzhoukesong | CJK Song style |
Zpix12 | 12px CJK pixel font |
Response Schema
The endpoint uses the HTTP status code to indicate the request result. The JSON response body only contains message.
Prop
Type
Status Codes
| HTTP status | Meaning | Description |
|---|---|---|
200 | Success | Text API content switched / Data updated but content not switched |
400 | Invalid parameters | Invalid icon format |
403 | Forbidden | You do not have permission to operate this device |
404 | Not found | Device not found or not registered Text API content not added to the loop task |
500 | Device response failure | Failed to switch Text API content |
Did this solve your problem?
Join our community