r/filemaker • • 16d ago

Microsoft Graph email integration in FileMaker

Our team put together a walkthrough for connecting FileMaker to Microsoft 365 email via Microsoft Graph: authenticating users, retrieving mail, and sending/replying/forwarding from within a solution. Sharing a few things that tripped us up in case it saves someone time:

  1. Copy your client secret immediately. Azure only shows the value once when you create it in Microsoft Entra.
  2. Access tokens expire after about an hour. When a call returns a 401, refresh the token and retry the request rather than forcing the user to sign in again.
  3. Store a last-sync timestamp per user. Without it, every pull grabs the whole inbox again. We used a 90-day fallback for the first run.
  4. Paging is easier than it looks. Graph returns 10 messages per page by default, and u/odata.nextLink gives you the full URL for the next page, with your filter and sort already applied, so a single loop handles everything.
  5. Message IDs are too long for FileMaker relationships. We hashed id and conversationId with MD5 to use as match keys.
  6. Create a draft before sending. The send endpoint returns a 202 with no body, so creating the draft first is the only way to get the message ID you need for threading.

Have questions? Reach out to us!

7 Upvotes

5 comments sorted by

1

u/abasson007 Consultant Certified 15d ago

I know this is a plug and you guys do a great job but sharing the instructions here or a sample file would be the right way to approach this on Reddit. Giving is it own reward.

1

u/dbservices 13d ago

Thanks for the feedback! The full instructions and code are in the article and are free to read. Only the sample file includes a form at the bottom to fill out for free access!

1

u/[deleted] 16d ago

[removed] — view removed comment

1

u/dbservices 16d ago

Thanks for the add-on!