vonage apps create 'Your application'
✅ Creating Application
Saving private key ... Done!
Application created
Name: Your application
Application ID: 00000000-0000-0000-0000-000000000000
Improve AI: Off
Private/Public Key: Set
Capabilities:
None Enabled
Créez votre Applications Vonage
Au cours de cette étape, vous allez créer un compte Vonage Applications capable d'utiliser la communication vocale in-app.
Ouvrez un nouveau terminal et, si nécessaire, naviguez jusqu'au répertoire de votre projet.
Créez une application Vonage en copiant et en collant la commande ci-dessous dans le terminal :
vonage apps create 'Your application'
✅ Creating Application
Saving private key ... Done!
Application created
Name: Your application
Application ID: 00000000-0000-0000-0000-000000000000
Improve AI: Off
Private/Public Key: Set
Capabilities:
None Enabled
Maintenant que votre application Vonage a été créée, mettez à jour votre authentification CLI avec l'ID de l'application et la clé privée :
vonage auth set `
--local `
--api-key='your-api-key' `
--api-secret='your-api-secret' `
--app-id='your-application-id' `
--private-key=C:\path\to\private.key
API Key: your-api-key
API Secret: your-**************
App ID: your-application-id
Private Key: Is Set
✅ Checking API Key Secret
✅ Checking App ID and Private Key
vonage auth set ^
--local ^
--api-key='your-api-key' ^
--api-secret='your-api-secret' ^
--app-id='your-application-id' ^
--private-key=C:\path\to\private.key
API Key: your-api-key
API Secret: your-**************
App ID: your-application-id
Private Key: Is Set
✅ Checking API Key Secret
✅ Checking App ID and Private Key
Ensuite, configurez les webhooks sur votre Application Vonage. Veillez à modifier les valeurs de --voice-answer-url et --voice-event-url en remplaçant les URL par https://SUBDOMAIN.loca.lt/voice/answer et https://SUBDOMAIN.loca.lt/voice/event respectivement. SUBDOMAIN est la valeur réelle utilisée à l'étape précédente :
vonage apps capabilities update 00000000-0000-0000-0000-000000000000 voice `
--voice-answer-url='https://example.com/webhooks/voice/answer' `
--voice-event-url='https://example.com/webhooks/voice/event' `
--voice-fallback-url='https://example.com/webhooks/voice/fallback'
✅ Fetching Application
✅ Adding voice capability to application 00000000-0000-0000-0000-000000000000
Name: Your application
Application ID: 00000000-0000-0000-0000-000000000000
Improve AI: Off
Private/Public Key: Set
Capabilities:
VOICE:
Uses Signed callbacks: On
Conversation TTL: 41 hours
Leg Persistence Time: 6 days
Event URL: [POST] https://example.com/webhooks/voice/event
Answer URL: [POST] https://example.com/webhooks/voice/answer
Fallback URL: [POST] https://example.com/webhooks/voice/fallback
vonage apps capabilities update 00000000-0000-0000-0000-000000000000 voice ^
--voice-answer-url='https://example.com/webhooks/voice/answer' ^
--voice-event-url='https://example.com/webhooks/voice/event' ^
--voice-fallback-url='https://example.com/webhooks/voice/fallback'
✅ Fetching Application
✅ Adding voice capability to application 00000000-0000-0000-0000-000000000000
Name: Your application
Application ID: 00000000-0000-0000-0000-000000000000
Improve AI: Off
Private/Public Key: Set
Capabilities:
VOICE:
Uses Signed callbacks: On
Conversation TTL: 41 hours
Leg Persistence Time: 6 days
Event URL: [POST] https://example.com/webhooks/voice/event
Answer URL: [POST] https://example.com/webhooks/voice/answer
Fallback URL: [POST] https://example.com/webhooks/voice/fallback
NOTE : Des informations sur votre application, y compris l'identifiant de l'application, peuvent également être trouvées dans la section Tableau de bord.
Recevoir un appel téléphonique in-app
Vous recevez un appel d'un téléphone vers votre application