Riposte Setup Guide: Standalone • PostgreSQL • In-memory queues • No webhooks • Google (Gmail) + Microsoft (Outlook)
Pre-generated Riposte setup wizard guide for standalone deployment with PostgreSQL storage. in-memory queues. no webhooks. provider coverage: google (gmail) + microsoft (outlook). advanced: opentelemetry. Includes installation, configuration, integration code, and operational callouts..
📋 Setup Overview
Pre-generated Riposte setup instructions for a standalone deployment backed by postgresql with in-memory queues and no webhooks.
What you'll build
Operate Riposte as a dedicated HTTPS service that your other applications call over the network—ideal when you want clear isolation or horizontal scaling.
PostgreSQL gives you durable, production-grade storage, ready for high-volume inbox synchronization and queueing.
Offer OAuth sign-in for both Gmail and Outlook users so every customer cohort can authorize their inbox securely.
Key ingredients
- Deployment Standalone
- Database PostgreSQL
- Queues In-memory queues
- Webhooks No webhooks
- Providers Google (Gmail) and Microsoft (Outlook)
- Advanced OpenTelemetry tracing and metrics
This recipe keeps the built-in in-memory queue, which is perfect for prototypes, QA environments, and quick internal tooling where simplicity wins.
Webhooks are skipped here, letting you focus on synchronous API integrations before introducing event-driven flows.
Advanced features enabled: OpenTelemetry tracing and metrics. Wire those signals into your observability stack before going live.
🚀 Installation & Bootstrap
Run the CLI to scaffold riposte/sync.config.json plus riposte/.env, then launch the managed runtime with npx riposte-run.
npm install @riposte.co/server
# Install the Riposte CLI
curl -sSL https://install.riposte.co/cli | bash
# Bootstrap a new Riposte workspace
# Initialize Riposte in a new directory
npx riposte-init my-riposte-project
cd my-riposte-project
# Edit riposte/sync.config.json (same shape as the runtime config below)
# Populate riposte/.env with your secrets, then launch the managed runtime
npx riposte-run
// Riposte managed runtime handles HTTP server & admin portal
// Deploy anywhere Node.js runs (Fly.io, Render, Railway, etc.)
.env (or your secrets manager) and reference them from the runtime config you pass to createRiposteServer.
http://localhost:8080. Passing adminPortal: true boots the portal with default admin/admin credentials—change them in the UI or via environment variables.
⚙️ Configuration
Drop these variables into .env (or your secrets manager) before booting the server.
Environment coverage
- 🔑 API key for SDK & REST authentication
- 🗄️ PostgreSQL database connection
- 📧 Google OAuth client credentials
- 🏢 Microsoft Entra application credentials
- 📊 OpenTelemetry exporter endpoint & service name
RIPOSTE_API_KEY=come-up-with-your-own-secure-api-key
DATABASE_URL=postgresql://postgres:postgres@localhost:5432/riposte
GOOGLE_CLIENT_ID=your-google-oauth-client-id
GOOGLE_CLIENT_SECRET=your-google-oauth-client-secret
GOOGLE_REDIRECT_URI=http://localhost:8080/providers/gmail/callback
MICROSOFT_CLIENT_ID=your-microsoft-entra-client-id
MICROSOFT_CLIENT_SECRET=your-microsoft-entra-client-secret
MICROSOFT_REDIRECT_URI=http://localhost:8080/providers/microsoft/callback
OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317
OTEL_SERVICE_NAME=riposte-integration
{
"database": {
"url": "env:DATABASE_URL"
},
"providers": {
"google": {
"clientId": "env:GOOGLE_CLIENT_ID",
"clientSecret": "env:GOOGLE_CLIENT_SECRET",
"redirectUri": "env:GOOGLE_REDIRECT_URI"
},
"microsoft": {
"clientId": "env:MICROSOFT_CLIENT_ID",
"clientSecret": "env:MICROSOFT_CLIENT_SECRET",
"redirectUri": "env:MICROSOFT_REDIRECT_URI"
}
},
"logging": {
"openTelemetry": {
"enabled": true,
"url": "env:OTEL_EXPORTER_OTLP_ENDPOINT",
"serviceName": "env:OTEL_SERVICE_NAME"
}
}
}
.env so the new credentials load into the runtime.CLI alignment:
riposte/sync.config.json mirrors these fields. Keep it in sync with .env before rerunning npx riposte-run.
📮 Providers
Console steps and environment variables for each provider you enabled.
🔍 Google Setup
Capture OAuth client credentials and drop them into your environment:
- Open Google Cloud Console and create OAuth client credentials.
- Configure the consent screen for external users if you haven't already.
- Use the scope planner to copy the Gmail + People API scopes you need.
- Set
GOOGLE_CLIENT_ID,GOOGLE_CLIENT_SECRET, andGOOGLE_REDIRECT_URIin.env, then restart Riposte.
Integration choices
- Connection mode: OAuth consent screen
- Accounts expected: 5
🏢 Microsoft Setup
Provision an Entra application so Riposte can access the right mailbox scopes:
- Create an app registration inside Microsoft Entra.
- Add delegated permissions for Microsoft Graph (Mail.Read, Mail.Send, etc.).
- Generate a client secret and copy the value before leaving the blade.
- Drop
MICROSOFT_CLIENT_ID,MICROSOFT_CLIENT_SECRET, andMICROSOFT_REDIRECT_URIinto.env.
Integration choices
- Connection mode: Delegated OAuth consent
- Accounts expected: 5
🔗 Integration Code
Call the Riposte REST endpoints or SDK from your backend using the API key issued in the admin portal.
import { createRiposteSdk } from '@riposte.co/sdk'
const sdk = createRiposteSdk({
apiKey: process.env.RIPOSTE_API_KEY!,
baseUrl: 'http://localhost:8080',
})
const { data } = await sdk.messages.list()
console.log('Messages:', data)
curl --request GET --url http://localhost:8080/api/messages --header "Authorization: Bearer $RIPOSTE_API_KEY"
RIPOSTE_API_KEY in your environment and include it as a bearer token on every request.
http://localhost:8080 by default.
const { authUrl } = await riposteSdk.authentication.createSession({ redirectUri: 'https://app.example.com/oauth/callback' })
⚡ Advanced Configuration
Optional features for production-ready deployments:
🔧 Enabled Features:
📊 OpenTelemetry Integration
Enable distributed tracing and metrics collection. The config snippets above already add logging.openTelemetry; just supply the exporter details:
# Add to your environment
OTEL_EXPORTER_OTLP_ENDPOINT=http://localhost:4317
OTEL_SERVICE_NAME=riposte-integration
Optional: Type your frontend with @riposte.co/api-types
Install in your frontend project with npm install @riposte.co/api-types to add lightweight type safety. This is optional, but it keeps your
UI code aligned with the API responses shown in this guide.
import type { ApiResponse, Message } from '@riposte.co/api-types'
type ThreadResponse = ApiResponse['/accounts/{accountId}/threads/{threadId}']['get']
const ThreadList = ({ threads }: { threads: ThreadResponse }) => {
return (
<div>
{threads.map((thread) => (
<div key={thread.id}>{thread.subject}</div>
))}
</div>
)
}
const MessageItem = ({ message }: { message: Message }) => {
return (
<div>
<div>{message.subject}</div>
<div>{message.body}</div>
</div>
)
}