Avo 4.0 documentation map
A map of every Avo 4.0 documentation page and its headings, designed for easy navigation by LLMs.
For the concise index, see llms.txt. For the full text of every page in one file (large — high token count), see llms-full.txt. For this map as raw markdown, see docs-map.md.
Auto-generated from the VitePress sidebar by
scripts/generate-docs-map.js. Do not edit manually.
Document structure
- ## marks documentation groups (e.g. 'Resources')
- ### marks individual documentation pages
- Nested bullets show the headings within each page
- Option names are grouped under their section; repeated pages link back without repeating their outline
- Each page title links to the full documentation
Avo 4
Getting Started
- The core
- Add-ons
- Your code
- Security
- Build it with AI agents
- Seamless upgrades
- Start here
- Where to go next
Upgrade Guide
Breaking changes and required actions by gem/version; fetch this page when upgrading.
Avo 3 to Avo 4 upgrade
Avo 3 to Avo 4 migration steps and breaking changes; fetch this page when upgrading from Avo 3.
Technical Support
🤖 Agentic engineering
- Code editors and LLM setup
- Pick your tool
- Other chat apps
- Skills
- Keeping them current
- Core
- Config & ops
- Customization
- Add-ons
- Cross-cutting
- One loader for every project
- MCP server
- Suggested workflow
AI
Overview
- Two ways in
- What holds on both
- Where to go next
Chat
- Requirements
- Installation
- Install the gem
- Run the installer
- Set your provider API key
- Add the admin resources to the menu
- Verify
- Teach the assistant your app
- Configuration
- Thinking
- Timestamps
- How the assistant works
- Record chips
- Answering the assistant's questions
- Your actions, from the chat
- Finding an action without naming its resource
- What it's allowed to run
- Undoing a run
- Tracing what it changed
- Files and attachments
- Getting new files in
- Reading files and importing from them
- Teach the assistant your app
- Let your coding agent write it
- The inventory
- Writing it by hand
- Customize the assistant's instructions
- Add your own instructions
- Rename the assistant
- Replace the shipped prompts
- Choose which tools the assistant gets
- Take a tool away
- Bring your own tool
- Serve the same tool over MCP
- Replace a shipped tool with your own copy
- See what a conversation will get
- Replace the assistant's icon
- What you start the chat from
- Starting from a Media Library file
- Starting from a conversation
- The rows you checked
- The page you were on
- Change how it reads
- Open the chat
- Use only full-page chats
- Closing idle tabs automatically
- Full-page chats
- The conversation menu
- Write a message
- Send files with a message
- What the composer accepts
- Protect the direct-upload endpoint
- Attach a skill with a message
- Import a skill
- Connect other tools with MCP
- Connect a server
- Share a connection
- Approve a call
- Manage a connection
- When a connection stops working
- Dictate a message
- Browser support, and where the audio goes
- While the assistant is replying
- When a reply fails
- When the worker dies mid-reply
- Where the failure is reported
- Who sees what went wrong
- When each message was sent
- Copy a message
- Rate a reply
- Review feedback
- Choose who can review feedback
- Turn feedback off
- Notify reviewers of new feedback
- Choose which models people can use
- Pinning the provider
- Switching model mid-conversation
- Choose who can manage skills
- Turn on MCP connections
- Set it up
- Choose who can connect and share
- Record remote calls in the audit log
- Before you open it up
- Turn the chat on or off per user
- Who can see a chat
- Who can delete a chat
- Debug levels
What you can ask
- Add a reusable skill
- Find records
- Count and break down
- Look around your admin
- Create records
- Change and delete records
- Undo something
- Run your actions
- Work with files
- Ask about the page you're on
- Ask about the rows you checked
- Ask about a file you sent
- Reach your other systems
- Manage the conversation
- What it won't do
Agents and tools
- The agents
- The chat agent
- The conversation renamer
- The tools
- Tools from connected MCP servers
- The shapes an ask can take
- Where tools get their context
- Schema comes back with the answer
- Renaming conversations
- Seeing a conversation's roster
MCP server
- Requirements
- Install
- Add the gem
- Run the installer
- Mount the endpoints
- Turn it on
- Decide who can use it
- Connect a client
- What the admin sees on the authorize page
- Choose what a connection can do
- Every call stays inside the admin's own permissions
- An action runs on the view it would have been started from
- Keep a field out of a client's reach
- Add tools of your own
- Share a tool with Avo AI
- Review and revoke connections
- What the status means
- Tell connections apart
- See and change what a connection may reach
- Read a connection's access at a glance
- Watch what a connection is doing
- Decide who sees and revokes what
- Turn MCP on or off per admin
- Run it in production
- Pin the server address
- Share the domain with your own OAuth server
- Behind a proxy or load balancer
- Rate limits
- Turn it off without losing the connections resource
- Keep credentials out of your logs
- Trace changes back to a connection
- Triage errors a client reports
- Full example
- Options reference
MCP Server reference
- Configuration
enabled,resource_identifier,issuer_path,tool_calls_per_minute,connection_log,connection_log_size,extra_tools
- Routing
mount_avo_mcp_server
- Generators
avo:mcp_server install,avo:mcp_server:tool
- Tools
- Arguments
- Capabilities
- Error codes
- Connection log
- Panel classes
- Policy methods
- Translations
- Rate limits
- Protocol
CLI
- Requirements
- Installation
- Install the gem
- Connect to your app
- Check what the token reaches
- Connect without logging in
- Look up what you can send
- Export an OpenAPI document
- List records
- Read one record
- Create a record
- Update a record
- Delete a record
- Send the right value for a field
- Key-value and code fields
- Files
- Long or awkward values
- Get JSON for a script
- Sign out
- When a command fails
- Exit 1: the app refused or did not answer
- Exit 2: the CLI refused before sending
- Command reference
Configuration
Installation
- Requirements
- Installing Avo
- Install the full Avo stack with your coding agent
- Install Avo core with one command
- Manual, step by step
- In popular Rails starter kits
- Bullet Train
- Jumpstart Pro
- Update Avo
- Commit and push the update
- Install from GitHub
- Mount Avo to a subdomain
- Next steps
Routing
- Default mounting behavior
- Mount Avo under a scope
- Mount Avo under a nested path
- Serve Avo from a custom map in config.ru
- Namespaced resource routes
- Add your own routes
Customization API
- Application
app_name,timezone,use_browser_timezone,currency,date_format,date_time_format,time_format,home_path,alert_dismiss_time
- Index view
per_page,per_page_steps,via_per_page,default_view_type,map_viewstyles
first_sorting_option,density,click_row_to_view_record,id_links_to_resource,cache_resources_on_index_view,index_cache_context,pagination,search_debounce,resource_row_controls_config
- Layout
container_width,sidebar,body_classes,hide_layout_when_printing,back_to_top
- Behavior
resource_default_view,persistence,associations,turbo,default_url_options,set_context,logger
- Development and generators
default_editor_url,view_component_path,model_generator_hook
- Status and metadata
exclude_from_status,send_metadata
- Routing
root_path,prefix_path
- Licensing
license_key,display_license_request_timeout_error,run_community_admin_without_valid_license
- Authentication
current_user_method,authenticate_with,sign_out_path_name,current_user_resource_name,is_admin_method,is_developer_method
- Authorization
authorization_client,authorization_methods,raise_error_on_missing_policy,explicit_authorization
- Localization
locale,locale_selector,model_attribute_translations
- Appearance
appearance
- Cache
cache_store
- Keyboard shortcuts
hotkeys
- Menus
main_menu,profile_menu,header_menu
- Breadcrumbs
set_initial_breadcrumbs
- Search
global_search,search_results_count
- Resources
model_resource_mapping,resources,resource_parent_controller,buttons_on_form_footers,warn_on_unsaved_changes
- Field discovery
column_names_mapping,column_types_mapping
- Fields layout
field_wrapper_layout,use_stacked_fields
- TailwindCSS
tailwindcss_integration_enabled,tailwindcss_content_sources
Gem server authentication
- On the server and CI systems
- Heroku
- Hatchbox
- GitHub Actions
- Add BUNDLE_PACKAGER__DEV to your repository's secrets
- Expose BUNDLE_PACKAGER__DEV as an environment variable
- Docker and Docker Compose
- Kamal
- On your local development environment
- Add Avo to your Gemfile
- Rotate the gem server token
- Bundle without the paid gems
- FAQ
- Forbidden 403
- Forbidden 403 in a sandboxed or cloud environment (Cursor Cloud)
License troubleshooting
- Check the license status page
- Read the status page states
- Frequent issues
- License key not properly set on the server, The sidebar status indicator is amber, License check blocked in the test suite
Authentication
- Customize the current_user method
- Rails authentication scaffold, Devise, Other methods
- Customize the profile widget
- Customize the sign-out link
- Customize the current user resource name
- Customize the entire sign-out path
- What signing out clears in the browser
- Filter out requests
- authenticate_with method
- User roles
- Admin user
- Check if a user is an admin
- When does Avo check if the use is an admin (is_admin?)
- Developer user
- Check if a user is an developer
- When does Avo check if the use is an developer (is_developer?)
- Customize the methods that check for roles
- Authorization
Authorization
- Set up authorization
- Write a policy
- Authorize association controls
- Reuse another policy for an association
- Authorize file attachments
- Limit which records a user sees
- Hide fields from a user
- Allow or deny fields
- What a withheld field is withheld from
- Trust each interface differently
- Combine with visible:
- Limits
- Let a user see a field but not change it
- Use a different policy for a resource
- Rename the policy methods Avo calls
- Handle missing policies
- When the license lapses
- When the license can't be validated
- Debug a denied action
- Use Action Policy
- Scope records with relation_scope
- Field lists and inherited association rules
- Authorize association controls with alias_rule
- Authorize without a signed-in user
- Keep policies under the Avo namespace
- Pass more context than the user
- Use CanCanCan
- Scope records with :index rules
- Name association rules on the record Avo asks about
- Hide fields with :read rules
- Use a different Ability for a resource
- Handle a nil user
- Use a different authorization library
- Manage roles with Rolify
Authorization API
- Configuration
authorization_client,explicit_authorization,raise_error_on_missing_policy,authorization_methods
- Resource options
authorization_policy
- Resource policy methods
index?,show?,new?,create?,edit?,update?,destroy?,act_on?,reorder?,search?,preview?
- Association policy methods
view_{association}?,attach_{association}?,detach_{association}?,create_{association}?,show_{association}?,edit_{association}?,destroy_{association}?,act_on_{association}?,reorder_{association}?,inherit_association_from_policy
- Attachment policy methods
upload_{FIELD_ID}?,download_{FIELD_ID}?,delete_{FIELD_ID}?
- Policy scope
Scope
- Field lists
whitelisted_fields,blacklisted_fields,Avo::Current.interface- Field list errors
- Client contract
authorize,policy,policy!,apply_policy,permitted_field_ids,field_reachable?
Performance
- Cache store selection
- Custom selection
- Row caching
- What invalidates a cached row
cache_resources_on_index_view,index_cache_context,cache_hash
- What a key cannot fix
- What invalidates a cached row
- Caching caveats
- Rows may not be automatically updated when certain associations change
- Option 1: Use touch: true on association
- Option 2: override cache_hash method on resource to take associations in consideration
- root_path change won't break the cache keys
- Rows may not be automatically updated when certain associations change
- Solid Cache
- Log ViewComponent loading times and allocations
- Enable ViewComponent Instrumentation
- Add Logging
Resources
Overview
- Overview
- Generate resources
- Alongside a model
- With the resource generator
- For all your models
- Fields
- Routing
- Name and describe records
- Avoid n+1 queries
- Control sorting
- Customize how records are fetched
- Customize pagination
- Control the saving flow
- Change how records are saved or destroyed
- Warn before deleting dependent records
- Tweak the Index view
- Record previews
- Manage sidebar presence and shortcuts
- Link to the record's public page
- Swap the view components
- Use multiple resources for the same model
- Namespaced resources
- Views
- Extending Avo::ResourcesController
- --parent-controller option on the generators
- resource_parent_controller configuration option
- Attach concerns to Avo::BaseController
- Manually registering resources
- Extending Avo::BaseResource
- Modify controls placement and appearance
- Cards
Resources API
- Identity
self.title,self.description,self.avatar,self.cover,self.icon,self.color,self.model_class
- Index view
self.default_view_type,self.view_types,self.default_sort_column,self.default_sort_direction,self.pagination- Examples
self.index_query,self.find_record_method,self.record_selector,self.keep_filters_panel_open,self.link_to_child_resource,self.index_view_loading
- Forms and saving
self.confirm_on_save,self.after_create_path,self.after_update_path,self.devise_password_optional,save_record,destroy_record,new_record,config.buttons_on_form_footers,config.warn_on_unsaved_changes- What counts as a change
- How the user is asked
- Not covered
- Navigation
self.visible_on_sidebar,self.hotkey,self.external_link
- Performance
self.includes,self.single_includes,self.attachments,self.single_attachments,cache_hash,cache_context
- Customization
index_slot,show_slot,edit_slot,new_slot,form_slot,view_slot,self.components,self.discreet_information
- Options documented on their own pages
Array Resource
- Paginate at the source
- Create, edit and delete
- Render it inside another resource
HTTP Resource
- Install the gem
- Generate a resource
- Parse the API response
- Send authentication headers
- Map sorting and filtering to query params
- Customize the backing model
- Handle API errors
- Customize create, update, and destroy
- Debug console
- Add it to the sidebar
- JSON API
- Full example
HTTP Resource API
- Request options
endpoint,headers,query_params
- Response parsing
parse_collection,parse_record,parse_count
- Model customization
model_class_eval
Scopes
- Generate a scope
- Register the scope on a resource
- Set a default scope
- Remove the "All" scope
- Show record counts
- Control who sees a scope
- Dynamic values
- Localization
- Or assign a callable
- Translating a label cannot break scope selection
- The cost of a callable
- Translating the gem's own chrome
- Limit index columns per scope
- Describe the selected scope in the header
- Full example
Scopes API
- Execution context
- Scope class options
name,description,scope,visible,countercounter.loading,counter.count,counter.visible,counter.format
fields,field_whitelist,field_blacklist
- Registration options
default,remove_scope_all
- Reading the selected scope
active_scope
Record reordering
- Set up reordering with acts_as_list
- Always show the order buttons
- Choose where the buttons appear
- Sort the Index view by position
- Reorder using drag and drop
- Custom position attribute
- Authorization
Record reordering API
- Ordering actions
actionshigher,lower,to_top,to_bottom,insert_at
- Visibility
visible_on,display_inline
- Drag and drop
drag_and_drop,position
Discreet information
- Show the record's ID
- Show timestamps without using a field
- Add a custom item
- Turn an item into a link
- Show an item conditionally
- Full example
Discreet Information API
- Preconfigured items
:id,:timestamps,:created_at,:updated_at
- Custom item options
as,text,title,icon,url,target,data,key,value,visible
Custom controls
- Add controls to dashboard headers
- Customize the show controls
- Customize the edit controls
- Customize the index controls
- Customize the row controls
- Keep the default controls
- What you can put in a control
- Links
- Built-in controls
- Actions
- Turbo triggers
- JavaScript triggers
- Group links and actions in a dropdown
- Conditionally show controls
Custom controls API
- Control areas
show_controls,edit_controls,index_controls,row_controls
- Controls
back_button,edit_button,show_button,save_button,create_button,attach_button,delete_button,detach_button,order_controls,actions_list- exclude
- include
action,link_to- target
- data
- class
list,divider,partial,refresh_button,default_controls
- Control options
label,title,style,color,icon,size,confirmation_message
Actions
- What happens when an action runs
- Generate an action
- Register the action on a resource
- Collect input with fields
- Choose an associated record
- Read a belongs_to field in handle
- Write the handle method
- Give feedback to the user
- Control what happens after execution
- Build a multi-step flow
- Customize the modal
- Run an action without records
- Work with every record on the Index
- Run actions from an association panel
- Use the panel's parent record
- Control visibility and authorization
- Trigger an action from a link
- Read params from the page that triggered the action
- StimulusJS
Actions API
- Registration
action,arguments,icon,divider
- Modal and appearance
name,description,message,confirm_button_label,cancel_button_label,confirmation,close_modal_on_backdrop_click,modal_width,hide_confirm_button,hide_cancel_button
- Behavior
standalone,visible,authorize,turbo
- The handle method
- Feedback methods
succeed,inform,warn,error,silent
- Response methods
reload,redirect_to,download,keep_modal_open,close_modal,do_nothing,navigate_to_action,append_to_response,reload_records
- Class methods
link_arguments
Select All
- How does it work?
- On the grid view
- Coming back to the index
- Serializing the query
- Serialization known issues
Cover and Avatar
- Add an avatar
- Add a cover photo
- Options
visible_on,source,size
Record chips
- Choose what the chip shows
- Give the chip a background
- Add fields that fit the answer
- Customize the hover text
- Keep links and authorization consistent
- Support streaming and reloads
Record chips API
- Chip declaration
chip,parttext,icon,tone
- Background
backgroundcolor,gradient,image,foreground
- Tooltip
chip_tooltip
- Dynamic fields
dynamic_fieldsenabled,only,except,limit
- Record resolution and layout
Views
- Index
- Add content to the index
- Show
- Edit
- New
- View groups
- Display
- Form
- Single
- Preview
- Checking the current view
- Multiple ways to check
- Common visible_on configuration values
- View types
- Restrict the available view types
Slots
- Choose the view and region
- Add content to the index
- Customize a single record page
- Share additions across Edit and New
- Keep custom inputs inside the form
- Choose a shared or view-specific replacement
- Support creation modals and repeated controls
- Add the same content to every resource
- Wrap or replace default content
- Use loaded records in slot content
- Keep slot rendering inexpensive
- Keep slots when customizing the index
- Troubleshoot missing or unexpected content
Resources API — outlined above.
Table view
- Row controls
- Global configuration
- Resource configuration
- Style rows with row_options
- Configuration shape
- Examples
- Highlight by record state
- Dim soft-deleted rows
- Branch on render context
- Conditional return values
- Hover and selection co-existence
- Dark mode
- Tailwind class discovery
- Performance
- Migration from row component overrides
- Limitations
Table view API
- Row controls
resource_row_controls_config,row_controls_config,placement,float,show_on_hover
- Row styling
table_view,row_options- Supported keys
class,data,style- Other HTML attributes
- Reserved data keys
- Denied attributes
Grid view
- Enable grid view
- Options
title,body,cover_url,badge
- Select records
- Make grid the default view
- Custom style
- Grid Item Badge
- Complete Example
- Options
badge.label,badge.color,badge.style,badge.title,badge.icon
Map view
- Enable map view
mapkick_options,record_marker,map,table,extra_markers
- Make it the default view
Custom view types
- Create the view type component
- Name the listing with list_frame_id and resource_name_for
- Register the view type
- Configure a resource to use it
- Full example: avo-notifications
- Add styles and interactivity
Fields
Fields
- Declaring fields
- Specific methods for each view
- Field conventions
- A more complex example
- Field types
- WYSIWYG & Markdown editors
- Which one should I pick?
- Shared Show view behavior
- Resizable editors
Field options
- Change the field label
- Show and hide fields on different views
- Show fields conditionally
- Hide fields that have no value
- Compute the value with a block
- Format displayed values
- On every view
- On specific views
- With Rails helpers
- Parse the value before saving
- Make columns sortable
- Sort computed fields and associations
- Mark fields as required
- Prevent users from editing a field
- Set a default value
- Add help text
- Add a tooltip
- Add a placeholder
- Focus a field when the form opens
- Place fields on the same row
- Stack the label above the value
- inline layout (default)
- stacked layout
- Global stacked layout
- Stack the label above the value
- Store empty values as NULL
- Link the table cell to the record
- Summarize a column
- Let users copy the value
- Align text on the Index view
- Customize the field components
- Eject the field components
- Point the field at your components
- Target a different database attribute
- Pass arbitrary data to the field
- React to changes in other fields
- Dependent select
- Derived value (slug from name)
Field options API
- Naming and description
name,translation_key,help,label_help,tooltip,label_tooltip,placeholder
- Visibility on views
show_on,hide_on,only_on,except_on,visible,hide_if_blank
- Formatting values
format_using,format_{view}_using,update_using
- Form behavior
required,disabled,readonly,default,nullable,null_values,autocomplete,autofocus
- Index view
sortable,summarizable,link_to_record
- Layout and rendering
width,stacked,html,components,copyable
- Advanced
for_attribute,meta,react_on
HTML attributes
- Declare the fields from the outside in
- The object notation
- The block notation
- Where are the attributes added?
- Index field wrapper, Show field wrapper, Show label target, Show content target, Edit field wrapper, Edit label target, Edit content target, Edit input target
Field discovery
- Scope which fields are discovered
- Pass options to every discovered field
- Combine manual and discovered fields
- Override how columns map to fields
Field Discovery API
- Method options
only,except,field_options
- Discovery behavior
- Mapping precedence
- Ignored columns
- Association defaults
- Global configuration
column_names_mapping,column_types_mapping
- Default mappings
- Column names
- Column types
- Associations
Layout
- Layout building blocks
- Header
- Group fields into panels
- How Avo computes panels
- Index view fields
- Move compact fields to a sidebar
- Organize fields under tabs
- Loading behavior on Show and Edit
- Durable and bookmarkable selection
- Position labels: inline vs. stacked
- Multi-column rows with width
Fields layout API
- Header
header
- Panels
paneltitle,description,visible
card
- Sidebar
sidebar
- Tabs
tabsid,title,description,visible
tabbadge,lazy_load,loading
Area
- Enable maps
- Store and edit coordinates
- Configure the area
- Display multiple polygons
- Customize the map
- Label and color the area
- Full example
Area API
- Geometry selection
geometry
- Map rendering
mapkick_options,datapoint_options
Array
- Set up the resource that renders each entry
- Supply data in a block
- Allow access to the panel
- Read data from the model
- Provide a fallback dataset
- Paginate at the source
- Choose which data source wins
- Customize shared field behavior
Array field API
- Data and resource selection
block,use_resource
- Pagination
per_page,discreet_pagination
- Loading and panel controls
loading,reloadable,linkable,refresh_on_destroy
- Listing controls
hide_search_input,hide_filter_button
Avatar
- Choose the avatar image
- Label the avatar column
- Configure shared field behavior
Avatar API
- Field-specific options
- Display defaults
- Image source and fallbacks
Badge
- Color-code statuses
- Emphasize a status
- Add a status icon
- Editing the value
- Custom labels with a Select field
- Show when a status changed
Badge API
- Color mapping
options
- Appearance
style,icon
Boolean
- Display a custom stored value as true
- Make missing values more visible
- Use a toggle on forms
- Options reference
Boolean API
- Interpret stored values
true_value,false_value
- Control presentation
nil_as_indeterminate,as_toggle
Boolean group
- Choose the available checkboxes
- Compute checkboxes from the record
- Keep unrelated stored keys when saving
- Customize shared field behavior
Boolean Group API
- Checkbox choices
options
- Shared field options
Checkbox list
- Define a fixed set of choices
- Load choices from records
- Add images to choices
- Help users find a choice
- Explain a limited set of results
- Save multiple selections
Checkbox List API
- Choice data
optionsid,title,description,avatar_url,image_url,image_format,image_alt,avatar_alt,hint
- Search within choices
inline_search
Code
- Highlight the right language
- Choose the editor colors
- Display more code on Show
- Control indentation
- Edit a JSON column
Code API
- Syntax and colors
language,theme
- Display
always_show,height,line_wrapping
- Indentation
tab_size,indent_with_tabs
- JSON values
pretty_generated
Country
- Enable country selection
- Display country codes instead of names
- Offer an empty selection
- Customize shared field behavior
Country API
display_code,default,include_blank- Common field options
Date
- Change how dates appear
- Start the calendar on Sunday
- Customize the calendar
- Use the same picker on mobile
- Link dates to their records
Date API
- Date formatting
format,picker_format
- Calendar behavior
first_day_of_week,picker_options,disable_mobile
Date time
- Change how dates and times look
- Display times in a specific timezone
- Customize the calendar
- Use common field options
DateTime API
- Display formatting
format,picker_format
- Timezone conversion
relative,timezone
- Picker controls
time_24hr,first_day_of_week,disable_mobile,picker_options
Easy MDE
- Enable spell checking
- Display the full content on Show
- Adjust the editor height
- Use common field options
EasyMDE API
- Editing
spell_checker,height
- Show content
always_show
External image
- Adjust the image for each view
- Open the record from an image
- Use computed values
- Show the image on grid cards
- Reference and shared options
External image API
- Image sizing
height,radius,width
- Record navigation
link_to_record
File
- Set up a single attachment
- Choose which files users can upload
- Upload large files directly to storage
- Choose where uploads are stored
- Customize the attachment preview
- Display a processed image variant
- Link index previews to the record
- Options reference
File API
- Uploads
accept,direct_upload,key
- Attachment display
display_filename,lightbox,link_to_record
Files
- Set up multiple attachments
- Control which files users upload
- Choose where uploads are stored
- Choose how attachments appear
- Preview images in place
- Display images from phones and design tools
- Authorize uploads, downloads, and deletion
- Configure shared field behavior
Files API
- Upload input
accept,direct_upload,key
- Attachment layout
view_type,hide_view_type_switcher,display_filename
- Image preview
lightbox
Gravatar
- Adjust avatars in the index table
- Display a fallback image
- Build the email address from the record
Gravatar API
- Index display
rounded,size,link_to_record
- Fallback image
default
Heading
- Choose the heading text
- Compute a heading for the show view
- Render formatted content
Heading API
- Heading content
label,as_html
- Common field options
Hidden
- Submit an existing attribute
- Let administrators choose the user
Hidden API
- Declaration
- Visibility
- Values and defaults
- Form submission
Id
- Open records from the ID column
- Disable sorting by ID
- Options reference
ID API
- Defaults and value behavior
- Record linking
link_to_record
Key value
- Customize the labels
- Suggest common keys and values
- Enforce restrictions
- Common field options
KeyValue API
- Labels and tooltips
key_label,value_label,action_text,delete_text,reorder_text
- Editing restrictions
disabled,disable_editing_keys,disable_editing_values,disable_adding_rows,disable_deleting_rows
- Suggested entries
suggestions
Lexxy
- Install the editor
- Store content with Action Text
- Display the full content
- Insert assets from the Media Library
- Customize the editor
Lexxy API
- Content display and attachments
always_show,attachments_disabled
- Editor configuration
preset,markdown,rich_text,multi_line,headings,toolbar,highlight,permitted_attachment_types
Location
- Display an interactive map
- Edit coordinates in separate columns
- Use a single coordinate attribute
- Customize the map's appearance
- Display a static map
- Options reference
Location API
- Coordinate storage
stored_as
- Map rendering
mapkick_options,zoom,static
Markdown
- Install the editor dependencies
- Write and preview Markdown
- Control file attachments
- Pass context to the preview renderer
- Customize the renderer
- Show the full content on the Show view
Markdown API
- Attachments
file_uploads,media_library
- Preview requests
extra_preview_params
- Show presentation
always_show
Money
- Install the field and monetize the attribute
- Choose the available currencies
- Edit the amount without changing the currency
- Use a different currency column suffix
- Preview the field in each view
- Create a record
- View a record
- Browse records
- Configure shared field behavior
Money API
- Currency selection
currencies,enable_currency
- Currency storage
currency_suffix
- Common field options
Number
- Limit the input range
- Formatting numbers
- Link a number to its record
Number API
- Input constraints
min,max,step
- Display formatting
format
Password
- Let users check their password
- Keep stored credentials out of the form
- Allow updates without changing a Devise password
- Configure shared field behavior
- Related
Password API
- Field-specific options
revealable
- View and value behavior
Preview
- Define the fields
- Label the preview column
- Control who can preview records
- Reference
Preview API
- Declaration and defaults
- Views and value contract
- Options
Progress bar
- Set the range and slider increments
- Show the value and its units
Progress bar API
- Range
max,step
- Value label
display_value,value_suffix
Radio
- Choose the available values
- Show choices as tabs
- Display stored values instead of labels
- Options reference
Radio API
- Define choices
options
- Control presentation
display_as,display_value
Record link
- Install the field
- Link to an associated record
- Choose which resource opens
- Leave navigation parameters out of the URL
- Using computed values
- Open links in another tab
- Common field options
Record link API
- Destination and navigation
use_resource,add_via_params
- Link browsing context
target
Rhino
- Install the editor
- Store rich text with ActionText
- Keep the full content visible
- Common field options
Rhino API
- Show view presentation
always_show
Select
- Define the available choices
- Compute choices for the current record
- Organize choices into groups
- Compute grouped choices
- Use a model enum
- Display stored values instead of labels
- Let users clear a selection
- Allow more than one selection
- Common field options
Select API
- Choice sources
options,grouped_options,enum
- Display and selection
display_value,include_blank,multiple
Stars
- Change the rating scale
- Set or clear a rating
- Options reference
Stars API
- Rating scale
max
Status
- Map your workflow to indicators
- Include neutral values in filters
- Edit the status value
Status API
- Indicator mappings
failed_when,loading_when,success_when
- Filter options
neutral_when
Tags
- Suggest tags to users
- Restrict the choices
- Adjust the dropdown
- Separate tags while typing
- Select a single value
- Search for suggestions remotely
- Display labels instead of stored IDs
- Store tags in a PostgreSQL array
- Integrate with acts-as-taggable-on
- Common field options
Tags field API
- Suggestions and restrictions
suggestions,enforce_suggestions,disallowed,suggestions_max_items,close_on_select
- Input and storage
delimiters,mode,acts_as_taggable_on
- Remote search
fetch_values_from
Text
- Link to an email address or phone number
- Link to the record
- Render HTML in a value
- Customize the label and input
Text API
- Display options
protocol,link_to_record,as_html
- Rendering precedence
Textarea
- Give longer text more room
- Show the field on the index
- Configure shared field behavior
Textarea API
- Input size
rows
Time
- Change how times look
- Keep the same clock time for everyone
- Customize the time picker
- Use common field options
Time API
- Display formatting
format,picker_format
- Timezone conversion
relative,timezone
- Picker controls
time_24hr,disable_mobile,picker_options
Tip Tap
- Choose the replacement editor
- Keep the full content visible
- Common field options
Tip Tap API
- Show presentation
always_show
Trix
- Show the full content
- Attach files to a saved record
- Attachments without an attachment_key
- Disable attachments
- Remove attachment attributes
- Active Storage
- Use Action Text
- Demo app
- Translate upload alerts
Trix API
- Content display
always_show
- File attachments
attachment_key,attachments_disabled
- Attachment metadata
hide_attachment_filename,hide_attachment_filesize,hide_attachment_url
Overview
- The model association has to exist first
- Common options
- Show or hide the association buttons
- Single Table Inheritance (STI)
- Link to child resource when using STI
- Add custom labels to the associations' pages
Searchable
- Requirements
- Boolean form
- Hash form
- query:
- enabled:
- item:
- Default options
- Polymorphic belongs_to
- With boolean form
- With hash form
Searchable associations API
- Boolean form
- Hash form
- Options
query- Polymorphic fields
item,enabled
Belongs to
- View and change the associated record
- Search a large set of records
- Choose among different model types
- Explain the two dropdowns
- Limit which records users can select
- Change the association when arriving through a parent
- Choose a different resource
- Options reference
Belongs to API
- Record selection
searchable,attach_scope,can_create,allow_via_detaching
- Polymorphic associations
polymorphic_as,types,polymorphic_help
- Resource resolution and links
use_resource,link_to_child_resource,link_to_record,target
Has one
- Choose which records users can attach
- React to an attach or detach
- Customize the association panel
- Explain the association
- Choose the associated resource
- Open the associated record
- Load an expensive panel on demand
- Remember an opened panel
- Attach through a join model
- Collect extra join attributes
- Show the panel while editing
- Edit the child in the parent form
- Remove a nested record
- Authorize nested changes
- Options
Has One API
- Attachment
searchable,attach_scope,attach_fields
- Attach and detach callbacks
before_attach,after_attach,before_detach,after_detach
- Panel presentation
description,use_resource,linkable,reloadable
- Frame loading
loadingmode,auto_load_for
- Nested forms
nestedon
Has many
- Choose which records to display
- Help users attach records
- Run code after attaching or detaching
- Attach through a join model
- Customize the panel
- Choose the resource for associated records
- Show the panel while editing
- Edit children with their parent
- Delete children when saving the form
- Authorize nested changes
- Control association actions
- Options reference
Has Many API
- Listing and resource selection
scope,for_attribute,use_resource,link_to_child_resource
- Attach picker
attach_scope,searchable,attach_using,attach_fields
- Attach and detach hooks
before_attach,after_attach,before_detach,after_detach
- Panel presentation and loading
name,description,loadingmode,auto_load_for
reloadable,linkable
- Table controls
per_page,discreet_pagination,hide_search_input,hide_filter_button,refresh_on_destroy
- Nested forms
nestedon,limit
Has and belongs to many
- Choose records to attach
- Filter the displayed records
- React to attaches and detaches
- Customize the panel
- Defer or refresh the table
- Keep descriptions cheap
- Choose a different resource or association
- Show the table on edit screens
- Edit related records in the parent form
- Authorize nested changes
- Control association buttons
- Options reference
Has And Belongs To Many API
- Attach picker
searchable,attach_using,attach_scope
- Displayed records and resource selection
scope,use_resource,for_attribute,link_to_child_resource
- Panel presentation
name,description,per_page,discreet_pagination,hide_search_input,hide_filter_button,linkable
- Loading and refreshing
loadingmode,auto_load_for
reloadable,refresh_on_destroy
- Attach and detach callbacks
before_attach,after_attach,before_detach,after_detach
- Nested forms
nestedon,limit
Filters
Overview
- Basic filters
- Dynamic filters
- Which one should you use?
- Common behavior
- Dive deeper
Basic Filters
- Generate a filter
- Register the filter on a resource
- Pick a filter type
- Boolean filter
- Select filter
- Multiple select filter
- Text filter
- Date time filter
- Group the options
- Reuse a select field's list
- Set a default value
- Populate options dynamically
- Compose filters that depend on each other
- React to other filters
- Show a message when there are no options
- Show or hide a filter conditionally
- Pass arguments to a filter
- Keep the filters panel open
- Link to a pre-filtered view
- Open a filter in your editor
Basic filters API
- Class options
self.name,self.button_label,self.visible,self.empty_message
- Instance methods
apply,options,default,react
- Runtime objects
applied_filters,arguments,params/request/view_context/current_user
- Date time filter options
self.type,self.mode,picker_format,picker_options
- Registration
filter
- URL encoding helpers
encode_filter_params,decode_filter_params,Avo::Filters::BaseFilter.encode_filters,Avo::Filters::BaseFilter.decode_filters
Dynamic Filters
- Authorize the attributes for Ransack
- How conditions combine
- Filter types
- Customize a filter
- Restrict or rename the conditions
- Write a custom query
- Filter across multiple columns or associations
- Offer suggestions or fetch values from an API
- Apply instantly, without the Apply button
- Humanize the filter pills
- Keep a filter in the bar
- Try the new filter dropdown
- Configure the filters bar
- Localization
- How the keys resolve
- Caveats
- Guides & Tutorials
- How to filter associations
- belongs_to example
- has_many example
- Composable filters
- The problem: repetitive filter code
- Method 1: helper method with field configuration
- Method 2: separate fields and filters with helper
- Method 3: programmatic filter generation
- Method 4: custom DSL with method override
- Choosing the right approach
- How to filter associations
Dynamic filters API
- The filter dropdown
- Filter options
label,icon,type,conditions,query,query_attributes,options,suggestions,fetch_values_from,render_apply_button,apply_on_select,pinned,inline,presets,humanized_value,humanized_condition
- Global configuration
button_label,always_expanded,param_key,simple_filters,inline_filters
- Filter types and their conditions
- Boolean
- Date
- Number
- Select
- Text
- Tags
- Field-to-filter mapping
Customize Avo
Customization
- Change the app name
- Timezone and currency
- Date and time formats
- Resource Index view
- Per-page pagination
- Default view type
- Map styles
- Sorting direction
- Row density
- Click a row to view the record
- Cache resources on the Index view
- Search debounce
- Modify controls placement and appearance
- ID links to resource
- Container width
- Upgrading from full_width_container / full_width_index_view
- Toggle the sidebar button visibility
- Resizable sidebar
- Change the starting width
- Turn resizing off
- Body classes
- Hide the layout when printing
- Send the user back to the top
- Home path
- Skip show view
- Open a record in your editor
- Resources
- Actions
- Filters
- Dashboards
- Cards
- Forms
- Context
- Alerts
- Persist UI state
- Associations
- Lookup list limit
- Association frames
- Turbo
- Default URL options
- Logger
- Status page
- Usage metadata
- Generators
- Custom view_component path
- Generate Avo resources alongside models
- Page titles
- Mount Avo under a nested path
- Custom query scopes
- Customize profile name, photo, and title
- Eject
- Breadcrumbs
Customization API — outlined above.
Eject views
- Eject a partial
- Prepared templates
- Eject a component
- Eject field components
- Scope ejected components
- Eject a controller
- Options reference
Menu editor
- Menu item types
- Add everything at once
- Sub-items
- Trigger actions from the menu
- Item visibility
- Authorization
- Add data attributes to items
- Icons
- Icon colors
- Keyboard shortcuts on menu items
- Collapsable sections and groups
- Default collapsed state
- Profile menu
- Forms in the profile menu
- Custom content in the profile menu
- Header menu
Menu editor API
- Structure items
section,group
- Item types
link_to,resource,dashboard,page,form,board,action,render
- Bulk helpers
all_resources,all_dashboards,all_pages,all_forms,all_boards,all_tools
- Shared options
visible,icon,color,hotkey,data,collapsable,collapsed
Search
- Enable search for a resource
- Run a different query per surface
- Search within associations
- Authorize search
- Limit the number of results
- Global search
- Direct record lookup
- Navigation section
- Configure the global search
- Hide a resource from the global search
- Customize how results render
- Custom search providers
Search API
- Resource configuration
query,item,hide_on_global,display_count
- search_type
- Global search configuration
enabled,navigation_section,search_on_type
- Limiting results
search_results_count
- Custom search providers
Keyboard Shortcuts
- Configure keyboard shortcuts
- Change or disable a shortcut
- Global shortcuts
- Appearance shortcuts
- Assistant
- Index view
- Show view
- Edit view
- Modals
- Assign hotkeys to the sidebar menu
- Add your own shortcuts
- Shortcuts hidden inside association panels
Keyboard Shortcuts API
- Switches
enabled,show_key_badges
- Bindings
bindings
- Hotkey syntax
- Shortcut IDs
- Core
- Add-ons
- Fixed keys
- Plugin shortcuts
register_hotkey
Localization (I18n)
- How Avo resolves a label
- The key map
- How the paths are derived
- Localizing resources
- Localizing actions
- Localizing scopes, cards, and dashboards
- Localizing fields
- Localizing tabs and panels
- Localizing the delete confirmation
- Localizing buttons label
- Setting the locale
- Locale selector
- Right-to-left locales
- Dates and the date picker
- Customize the locale
- What you can safely put under avo.
- Pluralization hashes accept extra keys
- Where your own keys go
- See which keys are taken
- What a collision looks like
- Add-on gems
- FAQ
- The I18n.t method defaults to the name of that field/resource
- Using a Route Scope for Localization
Appearance
- Customize the logo
- Desktop logo
- Dark mode logo
- Mobile logomark
- Favicon
- Placeholder image
- Set the default color scheme
- Choose a neutral palette
- Preset
- Custom neutral palette
- Choose an accent palette
- Preset
- Custom accent palette
- Restricting picker options
- Locking choices
- Persist picks across devices
- Cookie (default)
- Database
- How the blocks receive data
- Required schema
- Change the switcher layout
- Sound feedback
- Customize chart colors
- CSS customization
- Applying overrides
- Full example
- Options reference
Appearance API
- Theme selection
scheme,neutral,accent
- Custom palettes
neutral_colors,accent_colors
- Picker control
neutrals,accents,lock,picker_layout,sound,sound_button
- Persistence
persistence,load_settings,save_settings
- Assets
logo,logo_dark,logomark,logomark_dark,favicon,favicon_dark,placeholder
- Charts
chart_colors
- CSS variables
- Layout
- Fonts
- Top navbar
- Sidebar
- Table
- Focus ring
- Motion speed
Theming
- Do it by hand
- Recolor with the appearance config
- Re-skin with CSS variables
- Let an AI agent do it
- Change the font
- Load a hosted font
- Self-host the font files
- Fine-tune specific components
- Give each resource its own card colors
- Set a background image
- Style your custom UI
- Eject a view for full control
Multitenancy
- Breakdown
- Route-based tenancy
- Set the proper routing pattern
- Keep the tenant in every generated URL
- Set the tenant for each request
- Session-based tenancy
- Set the tenant for each request
- Add an account switcher
- See also
Custom tools
- Generate tools
- Controller
- Route
- Sidebar item
- Customize the sidebar
- What's available in your tool
- Set the page title
- Add assets
- Using helpers from your app
- Using path helpers
- For Avo paths
- For the main app paths
- Using path helpers
Resource tools
- Generate a resource tool
- Partial context
- Tool visibility
- Using path helpers
- For Avo paths
- For the main app paths
- Using path helpers
- Add custom fields on forms
- Where to add logic
Custom fields
- Generate a new field
- Start from an existing field
- Field options
- Field Visibility
- What's available in your components
- How the field wrapper ties it together
- Customize the views
- Field assets
- Collapse long content on Show
- Make an editor field resizable
- Use pre-built Stimulus controllers
- Hidden input controller
- Non existing model field
- Field methods
table_header_class
Custom errors
- Add a custom error
- Errors on a join record
- Where errors appear
Asset handling
- Supported asset pipelines
- How Avo ships its own assets
- Add your own CSS and JavaScript
- With Importmap
- With jsbundling and esbuild
- With rollup or webpack
- Manually (Sprockets or Propshaft)
- Load order and overriding Avo's styles
- Add custom styles or Tailwind classes
- Exclude Avo's assets from a CDN
- Add assets from a plugin
JavaScript & Stimulus
- Assign Stimulus controllers to resource views
- Field wrappers as targets
- Field inputs as targets
- All controllers receive the view value
- Assign Stimulus controllers to actions
- Attach HTML attributes
- Composing the attributes together
- Pre-made stimulus methods
- resource-edit#toggle
- resource-edit#disable
- resource-edit#debugOnInput
- Custom Stimulus controllers
- Use Stimulus JS in a tool
- Set up a controller
- Register that controller with the current Stimulus app
- Use the controller in the Avo tool
TailwindCSS integration
- Auto-enable behavior
- Add your custom Avo styles
- Override styles and scripts (avo-overrides.css / avo-overrides.js)
- Add behavior with Stimulus
- Disable integration (opt-out)
- Host content scan paths (tailwindcss_content_sources)
- Debugging
Plugins
- Overview
- Light layer
- Register the plugin
- Hook into Avo
- Hooks
avo_boot,avo_init
- Boot hooks must not load app classes
- Registration API
register(name, priority: 10),register_view_type(name, component:, icon:, active_icon:, translation_key: nil),register_field(method_name, klass),register_menu_item(name, &block),register_configuration(name, klass),installed?(name),mount_engine(klass, at:)
- Let apps configure your plugin
- Add asset files
- Using a middleware to surface asset files
- Create your own plugin
Avo.asset_manager
- Add a stylesheet file
- Add a javascript file
- Register a Stimulus controller
Concepts
Overview
- What's here
- What belongs here
Breadcrumbs
- Change the starting breadcrumb
- Add a breadcrumb
- add_breadcrumb options
title,path,icon,initials,avatar,color
- add_breadcrumb options
- Breadcrumbs for custom pages
Tooltips
- Add a tooltip to any element
- Use it with Avo's buttons and links
- Show rich, HTML tooltips
- Re-initialize after injecting markup
- Built-in tooltips
Icons
- How to use
- Libraries
- The Avo icons
- Tabler
- Example:
- Heroicons
- Examples:
- Use your own icons
Resource controllers
- Change where the user is redirected
- Customize the flash messages
- Return a custom response
- Change how records are saved or destroyed
- Use the parent record
Resource controllers API
- Create methods
after_create_path,create_success_action,create_fail_action,create_success_message,create_fail_message
- Update methods
after_update_path,update_success_action,update_fail_action,update_success_message,update_fail_message
- Destroy methods
after_destroy_path,destroy_success_action,destroy_fail_action,destroy_success_message,destroy_fail_message
- Persistence methods
save_record_action,destroy_record_action
- Parent record methods
via_record,via_resource
How pages are rendered
- The request lifecycle
- The before_action chain
- The action method
- Choosing the view component
- The layout
- The ERB template
- Turbo Stream responses
- Where to hook in
Rails engines and path helpers
- The rule
- Inside the Avo engine
- Linking to Avo pages
- Linking to your main application
- Linking to Avo add-ons
- Inside view components
- Why this matters
- Quick reference
- Learn more
Add-ons
Notifications
- Requirements
- Installation
- Install the gem
- Run the installer
- Run migrations
- Include the concern in your User model
- Configuration
- Sending notifications
- Who receives a notification
- Choosing a level
- Tagging with a type
- Adding action buttons
- From Avo actions
- From model callbacks
- From background jobs
- Notification states
- Reading notifications
- Bell component
- Real-time delivery
- How it works
- ActionCable setup
- Notification resource
- Scopes
- Bulk actions
- Customize the notification index
- Cleanup
Notifications API
- Configuration
ttl,realtime,dropdown_limit,user_class,user_display_name_method
- Send parameters
to,title,body,level,notification_type,url,sender,buttons
- Query and state API
for_user,unread_count,mark_all_as_read,cleanup_expired!, Per-notification state changes
- User model methods
unread_avo_notifications_count,mark_all_avo_notifications_read!,avo_notification_unread?
Media Library
- How to enable it
- Control who can use it
- Add it to the menu editor
- File previews
- Use it with the rich text editors
- Disable it on a single markdown field
Audit Logging
- Requirements
- Installation
- Install the gem
- Run the installer
- Migrate
- Enable and configure audit logging
- Enable it globally
- Configure author models
- Enable specific resources and actions
- Display logged activities
- Show activities on a specific record
- View and navigate activity logs
- Keep secrets out of the payload
- Change what an entry stores
- Enable change logs and revert changes
- Show all activity by an author
- Show an overview of all activities
- Change the date format
- Where an activity came from
- Mark your own origins
- Rename the origin labels
- Record activity from your own code
- Record changes no person made
- Log changes made outside Avo
- Pause logging for a block of code
- Read an activity in code
- When an activity has several records
- Always read the first record
- Control who sees which activities
- Show each user only their own activity
- Show the history of the records a user can see
- Disable specific actions logging
- Conclusion
Dashboards
- Generate a dashboard
- Settings
- Global ranges
- Localization
- Or assign a callable
- Refresh every card at once
- Add header controls
- Run actions from the header
- Cards
- Override card arguments from the dashboard
- Control the base settings from the parent
- Override card arguments from the dashboard
- Dashboards visibility
- Dashboards authorization
Dashboards API
- Identity and layout
self.id,self.name,self.description,self.grid_cols
- Ranges
self.global_ranges,self.refresh_button
- Header controls
self.controls,actions
- Visibility and authorization
self.visible,self.authorize
Cards
- Base settings
- description
- discreet_description
- Ranges
- Control the aggregation using ranges
- Keep the data fresh
- Refresh a card on demand
- Cache an expensive query
- Load cards only when they're needed
- Localization
- Or assign a callable
- It holds on the refresh path too
- The cost of a callable
- Translating the gem's own chrome
- Hide the header
- Format
- Metric card
- Calculate results
- Decorate the data using prefix and suffix
- Chartkick card
- Chart types
- Customize chart
- Partial card
- HTML card
- Inline ERB string
- Tag builder
- Renderables
- Table card
- Headers
- Row links
- Density
- Empty state
- Ranges and refreshing
- List card
- Cards visibility
- Dividers
- Dividers visibility
- View-specific card methods
- Resolution order by view
- Example
- Cards on association tables
- Show a card in a custom tool
- Let the user pick a range
- Size cards on a grid
Cards API
- Base settings
self.id,self.label,self.description,self.discreet_description,self.cols,self.rows,self.display_header,self.visible,self.refresh_every,self.refresh_button,self.loading,self.cache_for
- Ranges
self.ranges,self.initial_range
- Metric card
self.prefix,self.suffix,self.format
- Chartkick card
self.chart_type,self.chart_options,self.flush,self.legend,self.scale,self.legend_on_left,self.legend_on_right
- Partial card
self.partial
- HTML card
body
- Data cards (table & list)
self.fields,self.query,self.row_url,self.density,self.empty_message
- Registration overrides
card,arguments
- Dividers
divider
- Standalone card components
Avo::Cards::StandaloneCardComponent,Avo::Cards::MetricComponent
Kanban board
- Overview
- Requirements
- Installation
- DB schema
- Create a kanban board
- Create columns
- Configure the board
- Adding items to the board
- How does it work?
- Board and Columns
- Resources and Items
- Add items to the board
- Move items between columns
- Items without that property
- Customize the card
- Authorization
- Authorization Methods
- Customizing kanban models for your business logic
Calendar view
- Requirements
- Installation
- Install the gem
- Enable the view on a resource
- Configuration
starts_at,ends_at,title,week_start,default_period,hide_weekends,color,on_click
- All-day and hour-based events
- Month and week views
- Read a crowded day
- Event previews
- Navigation and filtering
- Pressing Today on today's own range
- Translate the calendar
- Customize the calendar index
Forms and pages
- Install the add-on
- Quick start
- How it works
- Generate forms and pages
- Build a form's fields
- Group fields with cards and panels
- Place fields side by side
- Prefill from a record
- Handle a form's submission
- Flash messages
- Restrict who can use a form
- Reusable vs. inline forms
- Render a form anywhere
- Organize pages
- Build a page's navigation
- Put forms on a page
- Set the container width
- Name the menu entry
- Add pages to the main menu
- Full example
- Best practices
Forms & Pages API
- Shared attributes
self.title,self.description,self.id,self.container_width
- Form attributes
self.authorize
- Form methods
fields,field,handle
- Page attributes
self.navigation_label
- Page navigation and content
navigation,page,form,content
REST API
- Installation
- Install the API tokens table
- Mount the API
- Mount options
- Endpoints
- Discovery
- The resource listing
- One resource's fields
- OpenAPI document
- Download the document
- Import it into your tool
- What is inside
- Authentication
- Create a token
- Send the token
- Token lifecycle
- A token acts as its owner
- Your app's own authentication still runs
- Keep the credential safe
- How the secret is stored
- Reading data
- Index
- Show
- Field serialization
- Writing data
- Create
- Update
- Delete
- Field value formats
- Entitle a token
- Grant a resource
- Read a token's access at a glance
- Take a token back to unrestricted
- Entitlements sit in front of your policies, never instead of them
- Tell the three refusals apart
- Who may change entitlements
- What entitlements don't cover
- Bring your own authentication
- Set the current user
- Authentication examples
- Authorization
- Custom controllers
- Your admin panel controllers are not inherited
- Array resources
- Accept writes
- What decides access
- Sorting
- HTTP resources
- Manage tokens in the panel
- Put it in the menu
- Who may manage tokens
- What each policy method controls
- Everyone manages their own tokens
- Freezing a revoked token
- Who sees the owner
- See what a token changed
- Works better with
- Localization
- Command line client
REST API reference
- Mounting
mount_avo_api
- Generators
avo_api:install,avo_api:generate,avo_api:tokens,avo_api:controller,avo_api:controllers
- Controller hooks
setup_authentication,self.setup_csrf_protection- Overridable methods
- Public API
Avo::Api.token_request?,Avo::Api::AuthenticationError
- Status codes
Collaboration
- Installation
- Enable collaboration on a resource
- Set the author name
- Watch property changes
- Customize reactions
- Place the timeline
- Authorization
- Extend the collaboration models
Collaboration API
- Resource configuration
author,watchers,reactions
- Timeline
collaboration_timeline
- Authorization
collaboration_view_timeline?,collaboration_create_entry?,collaboration_destroy_entry?
MCP Server — outlined above.
MCP Server reference — outlined above.
AI assistant — outlined above.
What you can ask — outlined above.
Agents and tools — outlined above.
Internals
Overview
- In this section
- Public Methods and Internal Usage
Testing
- Allow the license check host in your test suite
- Testing helpers
- Testing Actions
Avo::Current
user,params,request,context,view_context,locale,tenant_id,tenant
Avo::ExecutionContext
- How does the ExecutionContext work?
- Common objects
target,context,current_user,view_context,request,params,locale,main_app,avo, Custom variables,helpers,include
Avo::Services::EncryptionService
- How does the Avo::Services::EncryptionService work?
- Public methods
encrypt,decrypt
- Mandatory arguments:
message,purpose
- Optional arguments
- Public methods
- Usage example
- Basic text:
- Objects with custom serializer:
- Secret key base
Reserved model names and routes
- Model names to avoid
- Why these names are reserved
- Alternative approaches
- Using Avo with existing models
- Route Conflicts with resources :resources
- How to Fix It
Avo::ApplicationController
- On extending the ApplicationController
- Responsibly extending the ApplicationController
- Override ApplicationController methods