'How to find KnowledgebaseId in Dialogflow?

// const knowledgeBaseId = `the ID of your KnowledgeBase`;

I can't seem to find the knowledgebase ID in Dialogflow nor in the Cloud Console. Please help.



Solution 1:[1]

It's weird I my self couldn't find the KnowledgeBaseId even though I skimmed through dialogflow docs several times. But after several hours of searching I found a way that we could get it.

  1. You should go to the the Knowledge base you created and right side there is chat window where you can test your chatbot response.
  2. Type anything and you'll get a response card and below that there is an option called Diagnostic info.
  3. Click it and you'll see the RAW API response and there you can see the KnowledgeBaseId inside it (it may be referred as source there). It should be in the format Format: projects/<Project ID>/knowledgeBases/<Knowledge Base ID>

enter image description here

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 marc_s