Before using the voice navigation rule, the platform administrator must enable the use of the voice_helper rule; otherwise, the rule cannot be created, and if the functionality is disabled, the rule will be ignored in the IVR settings.
The API application permissions must be set to all (also enabled by the platform administrator, described in detail here: Creation and Authorization of Applications).
Voice Navigation - an IVR rule, the action description for voice_helper is available here: speech to text. This rule is set similarly to other IVR rules in the context options.
Below is the description of creating a rule, using examples of requests that can be performed on the interactive explorer page.
Creating a “voice_helper” voice assistant rule:
...
To add a rule, send the request
Code Block |
---|
bashCopyPOST code |
...
/api/ver1.0/extension/{extension_id}/ivr/context/{context_id}/options/{option_digits}/rules/ |
with the body:
Code Block |
---|
{ "action": "voice_helper", "voice_helper_classic_term": false, "voice_helper_digits_max": 1, "voice_helper_final_count": 1, "voice_helper_rules": [ { "to_option": 1, "transcription": "машина|техник" }, { "to_option": 2, "transcription": "косметика|косметолог" }, { "to_option": 3, "transcription": "гигиена|продукты" } ], "voice_helper_timeout": 12000 } |
...
If a specific sound greeting is required to inform the caller that a certain word is expected, a sound file needs to be prepared. The Sound Files resource (/sound/) will allow uploading a file and obtaining the file id.
...