Skill: Extract Document

Read a PDF someone shares with the Web Builder and return what it says about their business, such as name, contact details, services, opening hours and FAQ, so the agent can build a site from it.

Extract Document reads a PDF that someone shares in a chat with the Web Builder and returns what it says about their business. The Web Builder then builds or fills in a site from it. It comes with the Web Builder; its technical home is Horizon’s document extraction (docextract/v1.0/extract-document), but the Web Builder always runs it with one template made for websites.

It reads PDFs only, up to 50 MB, and writes nothing.

Parameters

ParameterTypeDescription
attachment_refstring or nullWhich shared PDF to read: the reference Horizon gives the file in the conversation. null reads the only PDF shared so far. If more than one PDF has been shared, null fails and lists them
template_idstringAlways the Web Builder’s template, Website content (used by the Web Builder)

The file is looked up within the same conversation and organization. The agent never holds a link to it.

What it returns

The extracted fields arrive in data, beside status, page_count, warnings and schema_valid. Anything the document doesn’t say comes back empty.

data fieldContents
business_nameThe name the business trades under
taglineA short slogan or one-line summary
aboutWhat the business does, who it serves and what sets it apart
phone, email, address, websiteMain contact details, and an existing website if the document names one
servicesA list, each with name, description and price
hoursA list, each with days and hours
faqA list, each with question and answer

The template also appears, read-only, in your organization’s document templates.


Related skills: Create Site | Update Site