Skip to content
ricochet

Dynamic Apps

Apps are content items that stay running to serve requests. Unlike tasks, which execute once and then stop, an app keeps a process alive to handle incoming HTTP traffic — for example a Shiny dashboard, a Plumber API, or a FastAPI service. Ricochet automatically manages the lifecycle of app processes, including scaling them up and down based on demand.

See the content items overview for the full list of supported app types.

When an app is deployed, ricochet starts its entrypoint script and expects the process to bind to a port. Ricochet routes incoming HTTP requests to the running process. If the app crashes, ricochet restarts it automatically.

Apps scale horizontally by spawning additional instances when connection thresholds are reached. Configure scaling behavior in the ricochet web UI or via the [serve] settings in your _ricochet.toml.

Shiny apps are interactive web applications. Use the content type shiny (or shiny-r).

The entrypoint can be a single app.R file or a directory containing ui.R and server.R.

[content]
name = "My Shiny App"
entrypoint = "app.R"
content_type = "shiny"

R Markdown and Quarto documents that use a Shiny runtime are deployed as apps rather than tasks because they require a live R process.

Content TypeDescription
rmd-shinyAn R Markdown document with runtime: shiny in its YAML header.
quarto-r-shinyA Quarto document with a Shiny runtime.
[content]
name = "Interactive Report"
entrypoint = "report.Rmd"
content_type = "rmd-shiny"

Plumber converts R functions into RESTful API endpoints using special comments.

[content]
name = "My Plumber API"
entrypoint = "plumber.R"
content_type = "plumber"

Ambiorix is a web framework for R inspired by Express.js. It can serve both web applications and APIs.

[content]
name = "My Ambiorix App"
entrypoint = "app.R"
content_type = "ambiorix"

The serverless-r content type lets you deploy plain R functions as a REST API without writing any web framework code.

The r-service content type is a generic option for R web apps or APIs that don’t fit the other categories. Your entrypoint script is run directly and must bind to the port specified by the PORT environment variable.

[content]
name = "Custom R App"
entrypoint = "app.R"
content_type = "r-service"

FastAPI is a modern Python web framework for building APIs. Ricochet launches FastAPI apps with uvicorn.

[content]
name = "My FastAPI App"
entrypoint = "app.py"
content_type = "fast-api"

Flask is a lightweight Python web framework for building web apps and APIs.

[content]
name = "My Flask App"
entrypoint = "app.py"
content_type = "flask"

Streamlit is a framework for building data apps in Python with minimal code.

[content]
name = "My Streamlit App"
entrypoint = "app.py"
content_type = "streamlit"

Dash is a framework for building analytical web applications in Python.

[content]
name = "My Dash App"
entrypoint = "app.py"
content_type = "dash"

Shiny for Python brings the Shiny framework to Python for building interactive web apps.

[content]
name = "My Shiny App"
entrypoint = "app.py"
content_type = "shiny-py"

The python-service content type is a generic option for Python web apps or APIs. Your entrypoint script is run directly and must bind to the port specified by the PORT environment variable.

[content]
name = "Custom Python App"
entrypoint = "app.py"
content_type = "python-service"

The julia-service content type deploys Julia web apps and APIs such as those built with Dash.jl. Your entrypoint script must bind to the port specified by the PORT environment variable.

[content]
name = "My Dash.jl App"
entrypoint = "app.jl"
content_type = "julia-service"

See the deployment guide for how to deploy apps using the CLI or via git integration, and the language-specific guides for project requirements: