-1

I want to make employee task schedule chat bot : for example employee A go to company X at 4pm, employee B go to company Y at 2pm. Chat bot should send task and reminder to employees, and employee A can see his tasks and not employee B tasks and the same apply for employee B.

Can you suggest how to make this chat bot using Dialogflow, and may be how to implement employee login (using username and password ) using Dialogflow. Many Thanks!

  • How is that a chatbot? It's basically just scheduled notifications. – Oliver Mason Jun 28 '21 at 10:19
  • Could explain if yo want to use a chat bot to schedule something and dave the appointment within the Calendar? Because this would be the use for a ChatBot. You could follow the instruction in this [tutorial](https://codelabs.developers.google.com/codelabs/chatbots-dialogflow-fulfillment#0), which explains how to create an appointment scheduler with DialogFlow and create an appointment within Google Calendar. Also, [this video](https://www.youtube.com/watch?v=oU88sHd6ilE) is very useful to understand the general concept of it. Did this information help you? – Alexandre Moraes Jun 28 '21 at 13:18

1 Answers1

1

Note that the main focus of Dialogflow is Natural Language Processing - Dialogflow is an NLU platform that makes it easy to design and integrate a conversational user interface into your mobile app, web application, device, bot, interactive voice response system, and so on.

If you want your chatbot to function as a task reminder that sends a message to its users based on a schedule, you’ll have to create your own implementation for it. On your custom backend, you’ll have to send a detectIntent request to your Dialogflow agent based on the user’s respective schedules.

You may check the respective documentation for ES detectIntent and CX detectIntent.

By default, Dialogflow is built in such a way that it will not provide a response unless it receives a user query from the end-user or an event from a client app first. However, based on your desired use case, the Dialogflow agent would have to initiate the conversation by sending a task reminder to the user.

To initiate a conversation with the user, you can try the following:

  1. If you are using a custom integration, you may use a custom event to initiate a conversation with the user.

    You can initiate a conversation by sending a detectIntent request to your agent to trigger a custom event. This lets your agent trigger a page with the custom event and send a response to the user without any user query or input.

    To create a Custom Event is Dialogflow ES, you can follow the steps as described in the Configure an intent for events section of the Events documentation. You can then invoke the event via API by filling the queryInput.event field in your detectIntent request body.

    To create a Custom Event in Dialogflow CX, you can follow the steps below:

    1. Inside your flow, select the page you want to add a custom event to then click the "Event handlers". If the "Event handlers" is not visible, click the “Add route type” button to add the Event handlers.
    2. Click on the + sign beside “event handlers” field and select any event.
    3. Tick the check box beside “Use custom event”.
    4. Add the name of the custom event you want to use.
    5. Add the desired response under “Agent says” Click save.

    You can then invoke the event via API by filling the queryInput.event field in your detectIntent request body.

    You can use Dialogflow ES’s Client Libraries and APIs or Dialogflow CX’s Client Libraries and APIs to create your own implementation/integration.

  2. If you wish to use built-in text-based integration, you can also utilize the Dialogflow ES Messenger / Dialogflow CX Messenger integration.

    You can utilize Dialogflow Messenger’s HTML “intent” attribute [ES/CX] to set an event to trigger the first intent when the chat dialog is opened.

    Here’s an example of how to add the custom event name as value for the “intent” attribute of Dialogflow Messenger’s HTML embed code:

    • Dialogflow ES Messenger enter image description here

    • Dialogflow CX Messenger enter image description here

    There are also JavaScript functions [ES/CX] available in which you may either choose from rendering a simple text message or a custom payload as an initial response to your end users. You may consider using the showMinChat [ES/CX] function to display a minimal version of the message list upon page reload.

    You may check the respective documentations for ES Integrations and CX Integrations for more details.

Moreover, note that Dialogflow does not have a built-in user login feature - it is up to your chatbot’s front-end to require the user to login. One possible way to add a login feature to your chatbot is by creating a custom front-end for your chatbot that provides a login interface.

hannah
  • 208
  • 1
  • 4