Flow scenario #5: Send a document to new member on joining group

Kaizala Developer Platform team

In a Managed Hub and Spoke group (Public Group) created for any event, it is a common requirement to send a message / document to the member who joins the group. I have picked up a case where a member joining the group would be sent a brochure (document) on joining the group. In order to achieve this in Flow, I would need to do the follow the below steps:

  1. Upload the document to Kaizala and get the Media Resource string
  2. Build a Flow to send the document to the subscriber joining the group

Upload document to Kaizala and get Media Resource string

We could avoid this step and directly upload the document / brochure in the same flow that would be sending the document. But I wanted to avoid uploading the same document to Kaizala each time a subscriber joins the group. This could be done by manually uploading the document to Kaizala using a REST client (like Postman) or a script using APIs. You could use the below API present in the Postman API collection for Kaizala (if you are new to Kaizala API, please refer Getting started with Kaizala APIs).

Screenshot of upload media

Once you choose the document and hit send, the API would return you a mediaResource string. Cache this string, we will be using it in the subsequent step.

Build a flow to send document to new subscriber

Now you could build a simple Flow to automate this scenario by going to https://flow.microsoft.com. It would just have one trigger and one action:

  1. Trigger: When member is added to a group
  2. Action: Send action on a group

Add the trigger: When member is added to a group

You can browse for connectors and triggers, search for Kaizala to select the Kaizala connector. Subsequently, search for the trigger “When member is added to a group” and add it. Configure it by selecting the group you want to build this scenario on.

Note: This group should be a Managed Hub & Spoke group (or Public Group) as a regular group does not support targeted sending of content. Also, the person joining should be a subscriber.

Screenshot of when a member is added to a group

Add action: Send action on a group

Click on add an action and search for “Send action on a group”. Configure the action by clicking on “Show advanced options” to reveal Subscribers field on the action.

  • Click the Subscribers field and select the Member Mobile Number from the dynamic content popup Screenshot of add dynamic content
  • Select document from the action dropdown
  • Select the group to which you want to send the document
  • Add a caption for the document
  • Paste the media resource string cached in the previous step into the Media Resource field

The following screenshot demonstrates this:

screenshot of send brochure

Click Update Flow to save the Flow.

Conclusion

This Flow would be triggered when a subscriber joins the group and would send the document targeted to the particular subscriber. The same could be replaced with sending an image / action.

Hope this was helpful. Do let me know if you have any comments / questions.

Feedback usabilla icon