# @twilio/voice-errors

> Voice Error Codes

Latest version **1.8.0** (published 2024-06-28) · BSD-3-Clause license · 0 weekly downloads

## Install

```sh
npm install @twilio/voice-errors
pnpm add @twilio/voice-errors
yarn add @twilio/voice-errors
bun add @twilio/voice-errors
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.8.0 |
| Published | 2024-06-28 |
| First published | 2019-07-10 |
| Weekly downloads | 0 |
| License | BSD-3-Clause |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 157.1 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Inaqui Delgado |
| Maintainers | Michael Huynh, Charlie Santos |

## Links

- npm: https://www.npmjs.com/package/@twilio/voice-errors
- npm.io page: https://npm.io/package/@twilio/voice-errors

## Recent versions

- 1.8.0 (latest) — 2024-06-28
- 1.7.0 — 2024-06-24
- 1.6.0 — 2024-05-29
- 1.5.0 — 2024-05-06
- 1.4.0 — 2023-09-28
- 1.3.1 — 2022-12-01
- 1.3.0 — 2022-11-22
- 1.2.2 — 2022-10-20
- 1.2.1 — 2022-10-19
- 1.1.1 — 2021-04-08
- 1.1.0 — 2021-04-08
- 1.0.1 — 2019-07-31
- 1.0.0 — 2019-07-10

## README

Twilio Voice Errors
===================

All Twilio Voice errors are defined in [`twilio-voice-errors.json`](twilio-voice-errors.json). Other errors already defined by Twilio are defined in [`twilio-authorization-errors.json`](twilio-authorization-errors.json) and [`twilio-rest-errors.json`](twilio-rest-errors.json).

-  Errors defined in [Twilio Client](https://www.twilio.com/docs/api/client/errors) are excluded from this branch. To ensure that new error codes do not overlap with previously defined errors, check [Twilio CLIENT error codes](https://www.twilio.com/docs/voice/client/errors) and [Twilio Error Codes](https://www.twilio.com/docs/api/errors).
- Programmable Voice uses the same error code range as Twilio Client.
- Authorization errors are defined using the `201xx` REST authorization errors instead of the range defined in Twilio Client as `312xx`.
- Twilio Error code `21218` is preferred over Twilio Client code `31001` for TwiML application not found.

Setup
-----

Ensure you have [Node](https://nodejs.org) installed. Then, run the following:

```
git clone https://code.hq.twilio.com/client/twilio-voice-errors
cd twilio-voice-errors
npm install
```

Usage
-----

### Previewing the Error Codes

This project can generate table and dictionary views of the Voice errors. Just
run the following command in the root of the project:

```
npm run generate
```

This will produce `dictionary.md` and `table.md`, respectively.

#### Previewing on GitHub

If you'd like to preview `dictionary.md` and `table.md` on GitHub, you can
automatically generate and push these artifacts to a dedicated
[`preview` branch](https://code.hq.twilio.com/client/twilio-voice-errors/tree/preview).
where you can see rendered versions of
[`dictionary.md`](https://code.hq.twilio.com/client/twilio-voice-errors/tree/preview/dictionary.md)
and [`tree.md`](https://code.hq.twilio.com/client/twilio-voice-errors/tree/preview/table.md)
rendered. Just run the following command in the root of the project:

```
npm run preview
```

### Publishing a New Version of this Specification to NPM

This project defines all Twilio Voice errors, so if you would like to add a new
error code, you must propose it and add it to this document, per
[`CONTRIBUTING.md`](CONTRIBUTING.md). Once added, you should cut a new _minor_
version of this document by updating the version number in package.json, eg
`1.0.0` -> `1.1.0`.

Make sure this version update has been committed and pushed to the primary branch.
Then, in order to publish to NPM, run:

```
npm publish
```

### Generic Twilio Errors

If you are using generic Twilio Errors that are not in `twilio-voice-errors.json`, add them to `twilio-rest-errors.json` or `twilio-authorization-errors.json` so that code can be generated for them as well.

### Code Generation

TODO: Implement code generation

---
_Source: https://npm.io/package/@twilio/voice-errors · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
