{"id":18755,"library":"revai-node-sdk","title":"Rev AI Node SDK","description":"Official Node.js SDK for the Rev AI speech-to-text API, enabling automatic speech recognition with features like async transcription, custom vocabulary, speaker diarization, language selection, summarization, and translation. Current stable version is 3.8.5, released under a regular cadence. Key differentiators include support for multiple input types (local files, URLs, audio streams), human transcription option, global deployment configuration, and full TypeScript typings. The SDK wraps Rev AI's REST API for job submission and retrieval.","status":"active","version":"3.8.5","language":"javascript","source_language":"en","source_url":"https://github.com/revdotcom/revai-node-sdk","tags":["javascript","rev_ai","Rev AI","speech","to","text","speechtotext","ASR","automatic speech recognition","typescript"],"install":[{"cmd":"npm install revai-node-sdk","lang":"bash","label":"npm"},{"cmd":"yarn add revai-node-sdk","lang":"bash","label":"yarn"},{"cmd":"pnpm add revai-node-sdk","lang":"bash","label":"pnpm"}],"dependencies":[{"reason":"Runtime dependency for TypeScript helpers when consuming as compiled JS.","package":"tslib","optional":false}],"imports":[{"note":"Library is ESM-first; require() fails in Node <12 or without esModuleInterop. From v3, CommonJS interop is not provided.","wrong":"const { RevAiApiClient } = require('revai-node-sdk')","symbol":"RevAiApiClient","correct":"import { RevAiApiClient } from 'revai-node-sdk'"},{"note":"Must use named import; default export is undefined.","wrong":"import RevAiApiDeploymentConfigMap from 'revai-node-sdk'","symbol":"RevAiApiDeploymentConfigMap","correct":"import { RevAiApiDeploymentConfigMap } from 'revai-node-sdk'"},{"note":"Enum is exported from main module; subpath imports are not supported.","wrong":"import * as RevAiApiDeployment from 'revai-node-sdk/RevAiApiDeployment'","symbol":"RevAiApiDeployment","correct":"import { RevAiApiDeployment } from 'revai-node-sdk'"}],"quickstart":{"code":"import { RevAiApiClient, RevAiApiDeployment, RevAiApiDeploymentConfigMap } from 'revai-node-sdk';\n\nconst accessToken = process.env.REVAI_ACCESS_TOKEN ?? '';\nconst client = new RevAiApiClient({ token: accessToken, deploymentConfig: RevAiApiDeploymentConfigMap.get(RevAiApiDeployment.US) });\n\nasync function main() {\n  const account = await client.getAccount();\n  console.log('Account balance:', account.balance);\n\n  const job = await client.submitJobLocalFile('./audio.mp3', { language: 'en' });\n  console.log('Job ID:', job.id);\n\n  const transcript = await client.getTranscriptObject(job.id);\n  console.log('Transcript:', transcript.monologues[0].elements[0].value);\n}\n\nmain().catch(console.error);","lang":"typescript","description":"Initializes a Rev AI client with an access token, submits a local audio file for transcription, and retrieves the result."},"warnings":[{"fix":"Change `new RevAiApiClient(token)` to `new RevAiApiClient({ token })`. Provide deployment config if needed.","message":"In v3, the client constructor no longer accepts only a token string; it requires an object with `token` and optional `deploymentConfig`.","severity":"breaking","affected_versions":">=3.0.0"},{"fix":"Use `getTranscriptObject(jobId)` and access structured fields.","message":"The method `getTranscriptText` returns raw text; use `getTranscriptObject` for structured data.","severity":"deprecated","affected_versions":"<=2.x"},{"fix":"Use `submitJobAudioData(stream, filename)` for streams.","message":"SubmitJobLocalFile expects the file path as first argument; do not pass a stream or Buffer directly.","severity":"gotcha","affected_versions":"*"},{"fix":"Always include `source_config: { url: '...' }` when using `submitJob` with a URL.","message":"The `source_config` object in job options must contain a `url` key for remote files; omitting it causes silent failure.","severity":"gotcha","affected_versions":"*"},{"fix":"Use Node 12 or later, preferably 16 or 18.","message":"Node 8, 10 are no longer tested; support was dropped in v3.5.0.","severity":"deprecated","affected_versions":">=3.5.0"}],"env_vars":null,"last_verified":"2026-04-25T00:00:00.000Z","next_check":"2026-07-24T00:00:00.000Z","problems":[{"fix":"Set `\"type\": \"module\"` in package.json, or use dynamic import: `const { RevAiApiClient } = await import('revai-node-sdk')`.","cause":"Using ES import syntax in a CommonJS project without ESM enabled.","error":"SyntaxError: Cannot use import statement outside a module"},{"fix":"Use `import { RevAiApiClient } from 'revai-node-sdk'` instead of `import RevAiApiClient from 'revai-node-sdk'`.","cause":"Using default import instead of named import.","error":"TypeError: RevAiApiClient is not a constructor"},{"fix":"Provide `deploymentConfig: RevAiApiDeploymentConfigMap.get(RevAiApiDeployment.US)` or other deployment.","cause":"Client initialized without a deployment configuration.","error":"Error: \"deploymentConfig\" is required but not specified"},{"fix":"Check the access token on your Rev AI settings page and ensure it is correctly passed to the client.","cause":"Access token is invalid, expired, or missing.","error":"Error: No account found with the given access token"}],"ecosystem":"npm","meta_description":null,"install_score":null,"install_tag":null,"quickstart_score":null,"quickstart_tag":null}