LogoRobo.js

Discord Activities

Discord Activities are interactive web applications that run directly inside Discord. They load within an embedded panel (iframe) in voice channels, text channels, and DMs, giving users a shared experience without leaving the app. Under the hood, activities are standard web apps built with HTML, CSS, and JavaScript — connected to Discord through the Embedded App SDK.

Robo.js brings a streamlined developer experience to activity development. Instead of wiring up separate frontend and backend projects, you get a unified project structure where your React (or vanilla) UI and API routes live side by side.

Built-in Cloudflare Tunnels (a secure connection that lets Discord reach your local computer) give you an HTTPS URL for testing instantly, and the @robojs/patch plugin handles Discord's proxy requirements automatically — no manual network patching needed.

The mental model is straightforward: your activity has a frontend (Vite — a fast build tool for web projects — powered UI in src/app/), a backend (file-based API routes in src/api/), and the Discord SDK connecting them to the platform. Robo.js ties these pieces together, adds a plugin ecosystem for features like real-time multiplayer and authentication, and handles the build tooling so you can focus on your app.

A Discord voice channel with an embedded activity running inside the panel, showing a custom web application rendered alongside the voice call participants

FocusThe activity running inside Discord's voice channel panel as an embedded iframeZoom100%NotesCapture Discord's desktop client with a voice channel open. An activity should be visible in the embedded panel showing a simple web app. At least one voice participant visible.

Quick Start

Create a new activity project:

npx create-robo@next my-activity

Select the activity kit when prompted. The CLI generates a project with frontend, backend, and Vite preconfigured.

Terminal output showing a new Robo.js activity project being created with the create-robo CLI, displaying scaffolding prompts and file generation

FocusThe create-robo CLI running in a terminal with the activity kit selectedZoom100%NotesShow terminal running 'npx create-robo my-activity' with the activity kit prompt visible or already selected. Dark terminal theme.

What Robo.js Provides

FeatureDescription
Unified projectFrontend and backend in a single project
Vite integrationPreconfigured Vite for fast development and builds
Built-in tunnelsFree Cloudflare tunnels for local testing
Proxy patching@robojs/patch handles Discord's proxy requirements
Authentication helpersOAuth2 token exchange with minimal setup
API routesFile-based HTTP endpoints via @robojs/server
Real-time syncMultiplayer state synchronization with @robojs/sync
TypeScript supportTypeScript works out of the box
Plugin ecosystemExtend functionality with installable plugins
  1. Quick Start — Create and run your first activity
  2. Credentials — Set up environment variables
  3. Developer Portal — Configure your Discord application
  4. Tunnels — Understand how tunnels connect Discord to your machine
  5. Frontend — Build the UI
  6. Backend — Add server-side logic and API routes
  7. SDK — Interact with Discord APIs from your activity
  8. Multiplayer — Add real-time features

Next Steps

On this page