How do I get specific id from specific DB?

(Marc Louie Cabigas) #1

For example this.

Or can I pot the school ID on the script?

Is there a way? Or I will do it with code, if yes please give a hint

(Daniel Beckett) #2

@mcfaith

I’m not sure what the user process would be here. Are you trying to capture the School ID when the user connects to the bot? If so, what platform are they connecting to the bot from? i.e. Facebook Messenger, Web Messenger, Telegram or Slack?

If the ID is already contained in a database then all you should need to do is connect to that database and query for the information. You’d need some kind of identifier from the user to find a match for School ID but that could be asked for when the flow starts if it’s not something automatically captured.

1 Like
(Marc Louie Cabigas) #3

I was trying do. eg. I have another website University website. Only school admin can access that website. But school admin has also its own website. so he/she will get the FLOW XO BOT from University Website and embed it to its own website. So when future leads or future student will visit on the school admin website he will then chat the bot, all the information will send to the University website not the School Admin Website. So, thats it but the problem is if i have many school admin who also have another website, so then i will create a table that uses school id, so that i can know that leads or future student are using that bot on that specific website.

Question is how can I get the School ID for the University website and when the school admin A for example have 12314 id and when he embed it the FLOW XO he/she id will be embed together at flow XO. Please help me

(Daniel Beckett) #4

Hi @mcfaith

You could pass metadata into the bot from the page to get an identifier. This can be done either by using the Web Messenger API or by adding parameters to the query string when you use the web messenger’s direct URL (for example, &foo=bar).

Metadata will be available inside the metadata output when you receive a new message through the bot.

1 Like
(Marc Louie Cabigas) #5

@DanielBeckett
Thank you very much