Easily integrate FileMaker and Google Calendar with Integromat
Hello.
I am Teruhiro Komaki of frudens Inc.
Since it was decided to speak at FM-Tokyo, I will tell you about it for the time being, although it is easy.
I will fix it later!
Demo file download
https://github.com/frudens/fm-tokyo-integromat
Integromat
Screen after login
It is the screen after login.
Select “Create a new Scenario”.
Select a service for scenario creation
Enter “web” and narrow down.
Select “Webhook” and select “Continue” in the upper right.
Create a scenario
“?” Is displayed in the middle.
Right click and select “Webhook”.
Select “Custom webhook” from Webhook Menu
The menu available on Webhook is displayed.
Select “Custom webhook”.
Publish Webhook URL
Publish the Webhook URL.
Select “Add”.
Set the name of Webhook
Any name is fine.
Let’s say “Create Google Calendar” here.
The Webhook URL was Published
For this URL, POST it using FileMaker Insert from URL and cURL option.
Select “Copy address to clipboard” and copy the URL.
Open demo file
Look for “demo_calendar_create.fmp 12” from the downloaded file and open it with FileMaker Pro 16.
Select the blue button at the top and switch the layout.
POST to URL
Paste the URL of the Webhook you just copied into curlUrl.
Select “post” at the bottom.
Make sure that the posted data is correctly sent to Integromat.
About post script
The post script is as follows.
post
Set variable
JSONSetElement ( "{}" ; [ "id" ; demo::id ; JSONString ] ; [ "start" ; demo::start ; JSONString ] ; [ "end" ; demo::end ; JSONString ] ; [ "title" ; demo::title ; JSONString ] ; [ "description" ; demo::description ; JSONString ] ; [ "location" ; demo::location ; JSONString ] )
Insert text
--request POST --header "Content-Type: application/json" --data-binary @$json
Return to Integromat and check the data
It is OK if “Successfully determined.” Is displayed.
Select “OK” and close.
Add module
Move the mouse closer to the right part of the created Webhook.
Select “Add another module”.
Add Google Calendar
In “Search” enter “Google Calendar” and narrow down.
Select “Google Calendar”.
Select “Create an Event”.
Configure Connection
Since “Connection” is not set at the beginning, select “Add” and authenticate “Integromat” with a Google Account.
By default, I think that it will be “My Google connection” by default.
Select an arbitrary calendar
The calendar of the authenticated Google Account will be loaded and available for selection.
Here, select “FM-Tokyo”.
Looking at the screen of Google Calendar, it is the place of “My Calendars” on the left.
Confirm POSTed data from FileMaker
Map JSON data set in the body of FileMaker’s “post script”.
When “Event name” is selected, the key of the JSON data is displayed.
In this case, set “title” to “Event name”.
Similarly for “start” and “end”, set the key.
When you are done, select “OK” and close it.
Test the scenario
Before testing the scenario, save it with “Save” at the bottom of the screen.
Select “Run once”.
Thunder beside the module turns round and waits.
Execute post from FileMaker
Go back to FileMaker from Integromat and run post.
Confirm the scenario
If there is no problem in the setting, the scenario ends normally.
Check Google Calendar
The JSON data Posted in FileMaker will be added to the calendar.
Confirm insertion response data from FileMaker URL
What is the insert response response data from the URL executed in FileMaker?
It is “Accepted”.
I really want you to return the id of the calendar you added, not “Accepted”.
By adding more modules here, you can retrieve the response data of the Google Calendar API.
Next time
This time, I wrote from FileMaker to adding Google Calendar events.
Next time, I will write response data acquisition, event information acquisition etc.
Afterword
People who are familiar with this type of service, please try to cooperate in various ways!
We will also write a link between FileMaker and DynamoDB, so please look forward to it!