i'm using dialogflow in application website but now stopped
readonly toKen = environment.dialogFlow.chatbotAngular;
readonly client = new ApiAiClient({accessToken : this.toKen});
conversation = new BehaviorSubject<Message[]>([])
constructor()
{
const botMessage = new Message('Bienvenue dans votre univers du chatbot,' +
' puis-je vous aider ?', 'bot','./assets/media/Awb/chatbot.gif','botcolor');
this.update(botMessage);
}
playAudio()
{
let sound = new Audio();
sound.src = './assets/media/to-the-point-568.ogg';
sound.load();
sound.play();
}
update(msg : Message)
{
this.conversation.next([msg])
}
converse(msg : string)
{
const userMessage = new Message(msg,'user','./assets/media/users/icon-5359553_1280.png','usercolor');
this.update(userMessage);
return this.client.textRequest(msg).then(res =>{
setTimeout(()=>{
const speech = res.result.fulfillment.speech;
const botMessage = new Message(speech, 'bot','./assets/media/Awb/chatbot.gif','botcolor');
this.update(botMessage);
this.playAudio();
}, 5000);
})
}
ERROR Error: Uncaught (in promise): ApiAiRequestError: The Dialogflow V1 API is shutting down and can no longer be queried. More details at https://cloud.google.com/dialogflow/docs/release-notes#June_15_2021. Code: 400