/assemblyai-pack:assemblyai-deploy-integrationfrom assemblyai-pack
Deploys AssemblyAI-powered transcription services to Vercel, Cloud Run, and Fly.io with secrets management and webhook configuration.
Ships in assemblyai-pack. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Deploy AssemblyAI-powered transcription services to Vercel (serverless), Google Cloud Run (containers), and Fly.io with proper secrets management and webhook configuration.
vercel, gcloud, or fly)# Add secrets
vercel env add ASSEMBLYAI_API_KEY production
vercel env add ASSEMBLYAI_WEBHOOK_SECRET production
# Deploy
vercel --prod
API Route for Transcription:
// app/api/transcribe/route.ts (Next.js App Router)
import { AssemblyAI } from 'assemblyai';
import { NextRequest, NextResponse } from 'next/server';
const client = new AssemblyAI({
apiKey: process.env.ASSEMBLYAI_API_KEY!,
});
export async function POST(req: NextRequest) {
const { audioUrl, features } = await req.json();
if (!audioUrl) {
return NextResponse.json({ error: 'audioUrl required' }, { status: 400 });
}
// Use submit() + webhook for production (non-blocking)
const transcript = await client.transcripts.submit({
audio: audioUrl,
webhook_url: `${process.env.NEXT_PUBLIC_APP_URL}/api/webhooks/assemblyai`,
webhook_auth_header_name: 'X-Webhook-Secret',
webhook_auth_header_value: process.env.ASSEMBLYAI_WEBHOOK_SECRET!,
speaker_labels: features?.speakerLabels ?? false,
sentiment_analysis: features?.sentiment ?? false,
});
return NextResponse.json({
transcriptId: transcript.id,
status: transcript.status,
});
}
Webhook Handler:
// app/api/webhooks/assemblyai/route.ts
import { AssemblyAI } from 'assemblyai';
import { NextRequest, NextResponse } from 'next/server';
const client = new AssemblyAI({
apiKey: process.env.ASSEMBLYAI_API_KEY!,
});
export async function POST(req: NextRequest) {
// Verify webhook authenticity
const secret = req.headers.get('x-webhook-secret');
if (secret !== process.env.ASSEMBLYAI_WEBHOOK_SECRET) {
return NextResponse.json({ error: 'Unauthorized' }, { status: 401 });
}
const { transcript_id, status } = await req.json();
if (status === 'completed') {
const transcript = await client.transcripts.get(transcript_id);
// Store transcript, notify user, trigger downstream processing
console.log(`Transcript ${transcript_id} completed: ${transcript.text?.length} chars`);
} else if (status === 'error') {
console.error(`Transcript ${transcript_id} failed`);
}
return NextResponse.json({ received: true });
}
Vercel config:
{
"functions": {
"app/api/transcribe/route.ts": { "maxDuration": 60 },
"app/api/webhooks/assemblyai/route.ts": { "maxDuration": 10 }
}
}
FROM node:20-slim
WORKDIR /app
COPY package*.json ./
RUN npm ci --only=production
COPY . .
EXPOSE 8080
CMD ["node", "dist/server.js"]
# Store secret in Secret Manager
echo -n "your-api-key" | gcloud secrets create assemblyai-api-key --data-file=-
# Build and deploy
gcloud builds submit --tag gcr.io/$PROJECT_ID/assemblyai-service
gcloud run deploy assemblyai-service \
--image gcr.io/$PROJECT_ID/assemblyai-service \
--region us-central1 \
--platform managed \
--set-secrets=ASSEMBLYAI_API_KEY=assemblyai-api-key:latest \
--allow-unauthenticated \
--memory 512Mi \
--timeout 300
# fly.toml
app = "my-assemblyai-app"
primary_region = "iad"
[env]
NODE_ENV = "production"
PORT = "3000"
[http_service]
internal_port = 3000
force_https = true
auto_stop_machines = true
auto_start_machines = true
min_machines_running = 1
fly secrets set ASSEMBLYAI_API_KEY=your-api-key
fly secrets set ASSEMBLYAI_WEBHOOK_SECRET=your-webhook-secret
fly deploy
// Endpoint to generate temporary tokens for browser streaming
// Works on any platform — the key is to never expose your API key to the client
import { AssemblyAI } from 'assemblyai';
const client = new AssemblyAI({
apiKey: process.env.ASSEMBLYAI_API_KEY!,
});
export async function GET() {
const token = await client.streaming.createTemporaryToken({
expires_in_seconds: 300,
});
return Response.json({ token });
}
import { AssemblyAI } from 'assemblyai';
const client = new AssemblyAI({
apiKey: process.env.ASSEMBLYAI_API_KEY!,
});
export async function GET() {
const start = Date.now();
try {
await client.transcripts.list({ limit: 1 });
return Response.json({
status: 'healthy',
assemblyai: { connected: true, latencyMs: Date.now() - start },
timestamp: new Date().toISOString(),
});
} catch {
return Response.json({
status: 'degraded',
assemblyai: { connected: false, latencyMs: Date.now() - start },
timestamp: new Date().toISOString(),
}, { status: 503 });
}
}
| Issue | Cause | Solution |
|---|---|---|
| Secret not available at runtime | Wrong env name or missing secret | Verify with platform CLI |
| Webhook not receiving events | URL not publicly accessible | Verify URL, check firewall/CORS |
| Function timeout (Vercel) | transcribe() takes too long | Use submit() + webhook pattern |
| Cold start latency | Serverless spin-up | Set minimum instances or use submit() |
For webhook handling, see assemblyai-webhooks-events.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
18 skills in this plugin
/assemblyai-ci-integrationConfigure AssemblyAI CI/CD integration with GitHub Actions and testing.
Use when setting up automated testing, configuring CI pipelines,
or integrating AssemblyAI transcription tests into your build process.
Trigger with phrases like "assemblyai CI", "assemblyai GitHub Actions",
"assemblyai automated tests", "CI assemblyai".
/assemblyai-common-errorsDiagnose and fix AssemblyAI common errors and exceptions.
Use when encountering AssemblyAI errors, debugging failed transcriptions,
or troubleshooting streaming and LeMUR issues.
Trigger with phrases like "assemblyai error", "fix assemblyai",
"assemblyai not working", "debug assemblyai", "transcription failed".
/assemblyai-core-workflow-aExecute AssemblyAI primary workflow: async transcription with audio intelligence.
Use when transcribing audio/video files, enabling speaker diarization,
sentiment analysis, entity detection, PII redaction, or content moderation.
Trigger with phrases like "assemblyai transcribe", "assemblyai transcription",
"transcribe audio", "speaker diarization assemblyai".
/assemblyai-core-workflow-bExecute AssemblyAI streaming transcription and LeMUR workflows.
Use when implementing real-time speech-to-text, live captions,
voice agents, or LLM-powered audio analysis with LeMUR.
Trigger with phrases like "assemblyai streaming", "assemblyai real-time",
"assemblyai live transcription", "assemblyai LeMUR", "assemblyai summarize audio".
/assemblyai-cost-tuningOptimize AssemblyAI costs through model selection, feature budgeting, and usage monitoring.
Use when analyzing AssemblyAI billing, reducing transcription costs,
or implementing usage monitoring and budget alerts.
Trigger with phrases like "assemblyai cost", "assemblyai billing",
"reduce assemblyai costs", "assemblyai pricing", "assemblyai budget".
/assemblyai-debug-bundleCollect AssemblyAI debug evidence for support tickets and troubleshooting.
Use when encountering persistent issues, preparing support tickets,
or collecting diagnostic information for AssemblyAI problems.
Trigger with phrases like "assemblyai debug", "assemblyai support bundle",
"collect assemblyai logs", "assemblyai diagnostic".
npx claudepluginhub flight505/skill-forge --plugin assemblyai-packOther plugins' skills for the same job