The Voxtelesys Node library provides the ability for Node.js applications to directly access Voxtelesys API services.
API | Documentation |
---|---|
Voice | https://voiceapi.voxtelesys.com/ |
This project will work with the following Node.js versions:
- Node.js 18
- Node.js 20
To install this project in your application, run:
npm i voxtelesys-node
In order to use the API client provided in this project, you must use an API token from the API Keys page in our Customer Portal. For example:
const client = require('voxtelesys-node')('[API_TOKEN]')
// make calls to any API using client
const VoxClient = require('voxtelesys-node').VoxClient
const client = new VoxClient('[API_TOKEN]')
const call = await client.calls.create({
to: '1234567890',
from: '1234567890',
voice_trunk_group_id: 90000,
voxxml: '<Response><Say>Hello from Voxtelesys!</Say><Hangup/></Response>'
})
console.log(call)
// output: { status: "queued" }
const VoiceResponse = require('voxtelesys-node').VoiceResponse
const response = new VoiceResponse()
response.say('Hello from Voxtelesys!')
response.hangup()
console.log(response.toString())
// output: "<Response><Say>Hello from Voxtelesys!</Say><Hangup/></Response>"