Control Text Content
Quick Guide
Prerequisites
- In the Playground, sign in to Dot and select Authorize. In a script, use a personal API key or an OAuth access token as a Bearer token.
- Get the serial number for a device you can control.
- Make sure your device is connected to power;
- Make sure your device is connected to the network;
- Use add device content to add
mindreset.text_apito the device’s loop or fixed list. You can leave the Dot API key field empty when adding the item.
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.
Choose a content list and display timing
Choose the loop list or fixed list; the loop list is used by default. A task identifier targets an item only in the selected list. Without an identifier, the first Text API item in that list is updated.
Enable immediate display for loop content to request a screen update while the device is online. A sleeping device on battery retrieves saved content after automatic wake. Fixed content follows the times configured in Dot. App: even the item currently on screen waits for the next scheduled refresh. The API preserves its time settings. Read Timing for details.
About icon input
An icon is optional. Send PNG Base64 data or a full 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
Each device accepts one immediate refresh request every 2 seconds. If you receive a 429, wait the number of seconds in Retry-After. See API rate limits.
Request Examples
/api/authV2/open/device/:deviceId/textGenerated Code
Before running an example, replace placeholders such as {{VARIABLE}} with actual values and remove the surrounding double braces.
1// Generating...Update content in the fixed list
In the List device content Playground, select the device and its fixed list. Find the item with contentId set to mindreset.text_api and copy its taskKey.
In the Playground on this page, select the same device and the fixed list (taskType: "fixed"). Enter the taskKey and the new content. The device shows the saved content at the next scheduled refresh. refreshNow applies only to the loop list.
Response Example
This is an example response for immediate display of loop content.
{
"message": "Device ABCD1234ABCD text API content switched."
}Troubleshooting
Endpoint
/api/authV2/open/device/:deviceId/text
Method
POST
Path Parameters
Prop
Type
Request Schema
Prop
Type
Default
loop
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 content list type Invalid icon format |
403 | Forbidden | You do not have permission to operate this device |
404 | Not found | Device not found or not registered Matching API content is missing from the selected list, or the task identifier does not match a Text API item in that list |
500 | Device response failure | Failed to switch Text API content |
Troubleshoot list selection and display timing
400: use onlylooporfixedfortaskType.404: ensure the request uses the sametaskTypeas the list query and ataskKeyfrom a matching API item in that list. OmittingtaskTypeselects the loop list.- Fixed content was saved but the screen did not change: check its time settings in Dot. App and wait for the next scheduled refresh.
refreshNow: truedoes not immediately refresh fixed content.
Reference Usage
- Simple text without immediate display
Enter a title and message in the Playground and set refreshNow to false. The saved text appears when the device reaches it in the loop.
- Complex text and display immediately
Enter a title, message, and signature in the Playground, and set refreshNow to true. For the title, use ChillDuanSans at size 30 and weight 700. For the message, use FusionPixel12 at size 22 and line height 1.25. For the signature, use ChillDuanSans at size 16.
- Complex text with icon and link, display immediately
Set refreshNow to true in the Playground. Enter PNG Base64 data or a public image URL in icon. Enter x-apple-health:// in link to open the Health app on tap.
- 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.
- 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" }Did this solve your problem?
Join our community