FlowRunner
Features Pricing
Theme
Start Free

Emailed load paperwork filed in a Google Drive folder per load

Rate cons, BOLs, PODs and carrier invoices arrive by email. This flow reads each one, finds the load in McLeod and files it in the load's Drive folder.

The prompt

When load paperwork arrives in our Gmail inbox, go through each PDF or image attached. Read it, tell me whether it's a rate con, BOL, POD, carrier invoice, lumper receipt or other paperwork, and pull out the load number. Skip logos and signature images. Find the load in McLeod by that number. If there's no load number on it, or McLeod has no such load, send it to ops in Slack instead of guessing. Otherwise find the folder named after the load number inside our Loads folder in Google Drive, create it if it isn't there, and upload the file named with the load number and the document type, like 0451873 POD.pdf.

FlowRunner Prompt to Flow built this flow from that request. Here it is as it opens in the editor.

The flow

Repeats for each item For each attachment Starts the flow New paperworkemail

Inside the loop: For each attachment

Yes No Yes No Yes Yes Yes No AI agent Read the document Condition PDF or image? Action File it in the loadfolder Condition Load number on it? Action Send it to ops Action Use the new folder Action Find the load inMcLeod Code Write the note for ops Action Save theattachment Action Use the load folder Condition Load in McLeod? Condition Load paperwork? Action Create the loadfolder Condition Load folder there? Code Check the file type Action Find the loadfolder

Download the file, then in FlowRunner click + beside Flows, pick it under Import a Flow Version and click Create. How importing works

What each step does

  1. New paperwork email Checks the inbox in Gmail every 5 minutes for an email with a PDF or image attached. Each attachment is handled on its own.
  2. Read the document Once the file is saved, an AI agent says whether it's a rate con, BOL, POD, carrier invoice, lumper receipt or other load paperwork, and reads the load number. Logos and signature images are skipped.
  3. Find the load in McLeod Looks the load up in McLeod by the load number on the document.
  4. Send it to ops A document with no load number, or a number McLeod doesn't know, goes to ops in Slack with a link to the file. Nothing is filed by guesswork.
  5. Find the load folder Looks inside your Loads folder in Google Drive for the folder named exactly after the McLeod load number.
  6. Create the load folder When the load has no folder yet, it's created inside the Loads folder.
  7. File it in the load folder Uploads the document named with the load number and its type, such as 0451873 POD.pdf, so every rate con, BOL and POD for a load sits in one folder.

Before you turn it on

  • Connect your Gmail, Google Drive and Slack accounts, and enter your McLeod server address with an API token or a user name and password.
  • Add your Anthropic key in the flow setting Anthropic key.
  • Set the flow setting Loads folder to the ID of the Google Drive folder that holds your load folders (the part of the folder's link after /folders/).
  • Pick your ops channel in Send it to ops, and narrow the Gmail search to your paperwork inbox if it shares a mailbox.