Learn how to make your Crust AI snippets interactive, allowing users to edit data or trigger actions via the AI prompt.
Make Your Snippets Interactive
While changing the visual design is a key part of customizing snippets, the AI prompt in Step 3 plays another crucial role: making your snippets interactive.
By default, snippets are read-only displays of your data. They show live information, but end-users cannot typically modify the data directly through the snippet interface.However, Crust AI allows you to add interactive elements, transforming your snippets from simple data viewers into functional mini-apps that can do things like:
Edit Specific Fields: Allow users to change the value of certain fields within a record directly from the snippet (e.g., update a status, check a box, edit value).
Trigger Buttons & Automations: Add buttons within the snippet that, when clicked, execute the action of a Button field in the corresponding record (often used to trigger automations, webhooks, or scripts).
Implement Conditional Logic: Make interactive elements appear or behave differently based on the data in the current record.
Just like visual customization, adding interactivity is achieved through natural language instructions in the AI Prompt input field (located below the phone preview in Step 3).You simply describe the functionality you want to add:
If the 'Status' is 'Pending Approval', add a button titled 'Approve Campaign' that changes the 'Status' field to 'Approved' AND triggers the URL of the 'Notify Client' button field.
(This demonstrates combining a field update and an action trigger in one interaction, conditional on the current status).
Snippet-Specific Functionality (e.g., Filtering the View)
The prompt can also add interactive elements that control the snippet’s view itself, rather than directly modifying data. For example:
Copy
Add filter buttons at the top that allow the user to filter the list by the 'Status' field.
Copy
Add a toggle switch to hide/show records where 'Priority' is 'Low'.
Important Distinction
These prompt-added filters operate only on the data already loaded into the snippet. They filter the records that have already passed the static Filters and user-based Permissions set in Step 2. They do not change the underlying data selection rules defined in Step 2. Think of them as convenient UI controls for the end-user to further refine the currently visible list.Learn more about setting Filters and Sorting.
By instructing the AI prompt, you can easily add powerful interactive capabilities to your snippets, allowing end-users to not only view but also interact with and update your data in a controlled and intuitive way.