-
Notifications
You must be signed in to change notification settings - Fork 0
Client SDK Demo
Doug Fennell edited this page Sep 26, 2025
·
1 revision
This page shows how to run the demo app and exercise it using the @rdcp.dev/client SDK.
- Node 18+
- Demo app running locally
npm run dev --prefix packages/rdcp-demo-app
The scripts read these env vars when present:
- RDCP_BASE_URL (default: http://localhost:3000)
- RDCP_AUTH_METHOD = api-key | bearer
- RDCP_CLIENT_ID (default: demo-client)
- RDCP_API_KEY (when api-key)
- RDCP_BEARER_TOKEN (when bearer)
- Client demo flows
npm run demo:client
- Auth examples (Basic and Bearer)
npm run demo:client:auth
- Benchmark: client vs direct fetch
npm run demo:benchmark
import { createRDCPClient } from '@rdcp.dev/client'
import { RDCP_HEADERS } from '@rdcp.dev/core'
const rdcp = createRDCPClient({
baseUrl: 'http://localhost:3000',
headers: {
[RDCP_HEADERS.AUTH_METHOD]: 'api-key',
[RDCP_HEADERS.CLIENT_ID]: 'demo-client',
'x-api-key': process.env.RDCP_API_KEY!,
},
})
await rdcp.getDiscovery()
await rdcp.getStatus()
await rdcp.postControl({ action: 'enable', categories: ['API_ROUTES'] })
await rdcp.getHealth()
Getting Started: Installation β’ Basic Usage β’ Authentication
Migration: From Manual Implementation β’ Framework Examples β’ Publishing Guide
Protocol: RDCP v1.0 Specification β’ Implementation Guide β’ API Reference
π Home | π¦ NPM Package | π GitHub | π Issues
RDCP SDK v1.0.0 - Runtime Debug Control Protocol implementation for JavaScript/Node.js applications
- Implementation-Status
- JavaScript-vs-TypeScript-Boundaries
- Core-Package-Boundaries
- Publishing-Setup
- Contributing
- API-Reference
- Protocol Specification
- Implementation Guide
- RDCP-Primitive-Types
- Protocol-Schemas
- Protocol-Error-Codes
- API-Reference
Version: 1.0.0
Protocol: RDCP v1.0
License: Apache-2.0