The `intercom-client` package provides the official Node.js and TypeScript bindings for interacting with the Intercom API. It is currently stable at version `7.0.3` and supports Intercom API v2.14 as of its v7.0.0 release. The library maintains a frequent release cadence, often driven by automatic code generation via Fern, ensuring it stays up-to-date with the latest Intercom API specifications. Key features include comprehensive TypeScript type definitions for request and response payloads, built-in support for paginated list endpoints through iterators, automatic request retries with exponential backoff for transient errors, and configurable request timeouts. It is designed for modern Node.js environments, requiring Node.js 18 or newer, and embraces ESM imports.
npm install intercom-clientVerified import paths — ran on the pinned version, not inferred.
Initializes the Intercom client using an environment variable for the API token and demonstrates how to make an API call (e.g., importing AI content) with robust error handling using `IntercomError`.
Review your API calls against the Intercom API v2.14 documentation and update code to match new endpoint signatures, request bodies, and response structures.
Ensure your project is configured for ESM (`"type": "module"` in `package.json`) and use `import` syntax for all package imports.
Wrap API calls in `try...catch` blocks and check if the caught error is an `instanceof IntercomError` to access detailed API error information.
Utilize the provided iteration patterns (`for await...of` or `page.hasNextPage()/getNextPage()`) to correctly traverse paginated results, as demonstrated in the library's usage examples.
Set the `INTERCOM_ACCESS_TOKEN` environment variable with your actual Intercom API token or pass `{ token: 'YOUR_TOKEN' }` directly to the `IntercomClient` constructor. For production, environment variables are recommended.Verify that your `INTERCOM_ACCESS_TOKEN` is correct and active in your Intercom workspace. Check if the token has the required scopes/permissions for the API endpoint you are calling.
Double-check the IDs or parameters used in your API call. Review the Intercom API documentation to confirm the correct endpoint path and resource existence.
The library has built-in retries, but for sustained high load, implement client-side rate limiting or back-off strategies in your application. Review Intercom's rate limit documentation.
No dependency data recorded yet.