Error on creating intent after createbotlocale

0

I am getting this error when I try to create bot locale and then intent after that, how can I handle this in java please ?

Create operation can not be performed on Intent when BotLocale is in Creating state. Retry your request after the BotLocale is created

I understand what it means but not sure how to handle this in the code. Can you please help ?

I am using java sdk lexv2.

preguntada hace 2 años332 visualizaciones
1 Respuesta
0

A bot locale is not immediately available after successfully invoking the CreateBotLocale API. The "botLocaleStatus" attribute in the response of CreateBotLocale and DescribeBotLocale will tell you the current status of the bot locale. You need to verify that the bot locale is in a valid state (NOT_BUILT) after invoking CreateBotLocale to successfully create intents in that bot locale. In the Java SDK, you can do this in two ways:

  1. Create a loop to poll for the status of the bot locale using DescribeBotLocale API
  2. Use a SDK waiter to poll that the bot locale is created and available. More info on SDK waiters
respondido hace 2 años

No has iniciado sesión. Iniciar sesión para publicar una respuesta.

Una buena respuesta responde claramente a la pregunta, proporciona comentarios constructivos y fomenta el crecimiento profesional en la persona que hace la pregunta.

Pautas para responder preguntas