Back to Templates

Extract Organizations & Summarize Documents with Foxit and Diffbot

Created by

Created by: Raymond Camden || raymondcamden

Raymond Camden

Last update

Last update a day ago

Share


How It Works

This N8N template demonstrates using Foxit's Extraction API to get information from an incoming document and then using Diffbot's APIs to turn the text into a list of organizations mentioned in the document and create a summary.

How it works

  • Listen for a new file added to a Google Drive folder. When executed, the bits are downloaded.
  • Upload the bits to Foxit.
  • Call the Extract API to get the text contents of the document.
  • Poll the API to see if it's done, and when it is, grab the text.
  • Send the text to Diffbot API to get a list of entities mentioned in the doc as well as the summary.
  • Use a code step to filter the entities returned from Diffbot to ones that are organizations, as well as filtering to a high confidence score.
  • Use another code step to make an HTML string from the previous data.
  • Email it using the GMail node.

Requirements

Next Steps

This workflow assumes PDF input, but Foxit has APIs to convert Office docs to PDF and that flow could be added before the Extract API is called.

Diffbot returns an incredible set of information and more could be used in the email.

Instead of emailing, you could sort documents by organizations into new folders.