ivona

0.1.0 • Public • Published

IVONA

ivona is a client library for IVONA Text-to-Speech SaaS written in Node.js.

Installation

$ npm install ivona

Usage

var ivona = new (require('ivona'))({
  email: IVONA_LOGIN_EMAIL,
  key: IVONA_API_KEY
});

API (documentation)

The client automatically handles token authentication therefore the following API calls can be made right away.

token and md5 parameters can be omitted or specified.

Create Speech File

ivona.createSpeechFile({
  text: '...',
  contentType: '...',
  voiceId: '...',
  codecId: '...'
}), function (err, fileId, soundUrl) {
  // ...
});

Create Speech File w/ Marks

ivona.createSpeechFileWithMarks({
  text: '...',
  contentType: '...',
  voiceId: '...',
  codecId: '...'
}), function (err, fileId, soundUrl, marksUrl) {
  // ...
});

Delete Speech File

ivona.deleteSpeechFile({
  fileId: '...'
}, function (err, success) {
  // ...
});

List Speech Files

ivona.listSpeechFiles(function (err, speechFiles) {
  // ...
});

Get Speech File Data

ivona.getSpeechFileData({
  fileId: '...'
}, function (err, result) {
  // ...
});

Get Speech File Data w/ Marks

ivona.getSpeechFileDataWithMarks({
  fileId: '...'
}, function (err, result) {
  // ...
});

List Pronunciation Rules

ivona.listPronunciationRules({
  langId: '...'
}, function (err, rules) {
  // ...
});

Add Pronunciation Rule

ivona.addPronunciationRule({
  langId: '...',
  stat: #,
    // 1 – simple substitutions, case insensitive
    // 2 – simple substitutions, case sensitive
    // 3 – regular expressions
  key: '...',
  value: '...'
}, function (err, success) {
  // ...
});

Modify Pronunciation Rule

ivona.modifyPronunciationRule({
  langId: '...',
  id: '...',
  stat: '...',
  key: '...',
  value: '...'
}, function (err, success) {
  // ...
});

Delete Pronunciation Rule

ivona.deletePronunciationRule({
  langId: '...',
  id: '...'
}, function (err, success) {
  // ...
});

Check Text Price

ivona.checkTextPrice({
  text: '...',
  voiceId: '...'
}, function (err, price) {
  // ...
});

Get User Agreement Data

ivona.getUserAgreementData(function (err, result) {
  // ...
});

List Voices

ivona.listVoices(function (err, voices) {
  // ...
});

List Voices Extended

ivona.listVoicesExtended({
  locale: '...'
}, function (err, voices) {
  // ...
});

Get Voice Data

ivona.getVoiceData({
  voiceId: '...'
}, function (err, result) {
  // ...
});

List Codecs

ivona.listCodecs(function (err, codecs) {
  // ...
});

Credits

See the contributors.

License

ivona is released under the MIT License.

Package Sidebar

Install

npm i ivona

Weekly Downloads

0

Version

0.1.0

License

MIT

Last publish

Collaborators

  • huh