Generate AI Dashboard
POST/dashboard/:dashboardID/generate
Generate or refine the layout of an AI Dashboard from a prompt, the same as the prompt bar in Admin. Each call that changes the layout replaces the stored one and saves a new version. A call that changes nothing saves no version, but still counts as a generation.
Experimental. This feature may change or be removed.
See AI Dashboard for how the layout is built.
Without run_user, the request edits your own setup. With run_user, it builds or edits that TagoRUN
user's own version on a dashboard with Per Run User Generation
on. The generator then sees only the devices that user can access, and follows the dashboard's
ai_instructions.
Requires a profile token with Full or Write permission, or an Analysis token whose Access Management policy allows Dashboard → Edit on the dashboard. Generations count against the profile owner's AI requests, or spend AI credits on a paid model. See TagoAI Service.
A generation usually takes 15 to 60 seconds and times out after 120 seconds. Only one generation runs at a time on your setup or on each user's version, and at most three at once per profile. Send the next request for the same user after the previous one finishes, and do not retry blindly after a timeout: each run is billed and can save a version.
Request
Responses
- 200
- 400
- 401
- 402
- 404
- 429
- 504
Layout generated and saved
Invalid body (an empty or too long prompt, too many history entries, or an unknown field), AI disabled for the profile, or a generated layout that failed validation.
The token cannot generate: a read-only profile token, a TagoRUN user token, or an Analysis token without Dashboard → Edit on the dashboard.
The monthly free model allowance is used up, the AI credit balance is too low, or the profile spend cap is reached.
The dashboard is not an AI Dashboard of this profile. With run_user, also when Per Run User Generation is off, or the user is unknown, inactive, or has no Dashboard → Access to the dashboard.
Your setup or this user's version is already generating, or the profile already runs three generations. The Retry-After header gives the seconds to wait.
The generation did not finish within 120 seconds.