All articles

Data & connectors

Save a PDF to the HubSpot record

When someone generates a document from a HubSpot record with the Weft panel, Weft can offer to save the PDF back onto that record: a quote onto its deal, a letter onto its contact. Nothing is saved on its own. The person sees the PDF first, then presses Save to HubSpot.

The PDF lands the way a file dragged into HubSpot does: as a private file in HubSpot's file manager, attached to a new note in the record's timeline. A private file is not reachable by a public link; people open it from the note in HubSpot.

Before you start

  • The template needs to work from the Weft panel — see Generate a PDF from a HubSpot record. Saving works on deals, contacts, companies and custom objects (custom objects come with paid HubSpot plans). It does not work on tickets.
  • Saving uses the person's own HubSpot login, so the template must keep Each user connects their own HubSpot ticked. With shared access on, saving is switched off.
  • Turning saving on or off needs the editor role or higher.

Turn saving on or off

New templates start with saving on, so the button is there as soon as the template works from the Weft panel. To change it:

  1. Open the template's Data sources window: the data pill above your document, then Manage sources….
  2. Under Save to the HubSpot record, choose:
    • Save as a file — a private file on a note in the record's timeline.
    • Off — no save; people download the PDF.

The choice applies straight away. You don't need to publish again.

When the template's first data source reads something saving doesn't work on — tickets, line items, products or quotes — the setting shows Off and says Save to HubSpot works on deals, contacts, companies and custom objects. Your choice is kept, and comes back when the data source reads an object saving works on.

Custom objects

A note reaches a record through a link that HubSpot sets up for each kind of record. For a custom object, each HubSpot account has its own link, so when you create or change a data source that reads a custom object, Weft asks HubSpot for it and keeps the answer with the data source.

  • HubSpot has no note link for the object. Saving can't work there, so Save to the HubSpot record stays off and says HubSpot has no note link for the object, so Weft can't attach PDFs to these records.
  • Weft couldn't ask HubSpot just then. The data source is saved anyway, saving stays on, and the window says Weft will check with HubSpot when someone saves.
  • The link changed — for example, the custom object was deleted and created again under the same name. After you save the data source, the window says Saving to HubSpot now uses this HubSpot account's object link. There is nothing to choose or type.

If a save finds HubSpot no longer accepts the link Weft kept, Weft asks HubSpot for the current one and adds the note once more, without uploading the file again.

Name the file

Under File name in the same window, type the name you want, with fields from the record in curly brackets — for example Quote - {Deal.dealname} - {today}. Insert field lists today's date and every field your data source reads. A field that is empty for a record simply drops out. Press Save name; Use default goes back to the template name and the date. The same name is used when someone presses Download PDF. A field you add to the data source fills the name once you publish the template.

Reconnect HubSpot once after this update

Saving needs two HubSpot permissions that earlier connections did not ask for: to upload files, and to add a note to the record. So the first time someone presses Save to HubSpot on a connection made before this update, the page says Reconnect HubSpot to allow saving, with a Reconnect HubSpot button beside it.

  1. Press Reconnect HubSpot and approve HubSpot's consent screen. You can also do it in Weft: Settings → Integrations, then Reconnect on the HubSpot connection's row.
  2. Press Save to HubSpot again.

Each person reconnects once, for their own login. Nothing was saved by the attempt that asked.

What people see

Next to Download PDF, the page shows Save to HubSpot. Pressing it saves the PDF as a new file and shows Saved to HubSpot ✓, with Open record to go back to the record in HubSpot.

  • Every save is a new file. HubSpot files have no versions, so there is no Save as new version for HubSpot; saving the same document again adds another file.
  • The file is named by the template's File name setting, or after the template and the date — the same name Download PDF gives the PDF.
  • Saving twice from the same page is refused; generate the document again to save another copy.
  • The save runs on the HubSpot login of the person who pressed Save, so HubSpot applies their own permissions.

Size limit

HubSpot's free plan accepts files up to 20 MB, and Weft holds every HubSpot save to that limit. A larger PDF shows Too large to save to HubSpot (20 MB max) instead of the button; download it instead.

If saving fails

What the person seesUsually meansWhat to do
Reconnect HubSpot to allow savingTheir HubSpot connection was made before saving existedPress Reconnect HubSpot, approve, then Save to HubSpot again
"This record no longer exists in HubSpot, or you can't see it"The record was deleted or is hidden from themCheck the record in HubSpot
"You don't have permission to upload files in HubSpot"Their HubSpot permissions don't include the file managerAsk your HubSpot admin, then press Try again
"You don't have permission to add notes to this record in HubSpot"Their HubSpot permissions don't allow notes on that recordAsk your HubSpot admin, then press Try again
"The PDF is too large for this HubSpot account's plan to accept"HubSpot refused the file's sizeDownload it instead
HubSpot didn't confirm the saveThe file left, but no answer came backCheck the record's notes first. Only if the PDF is not there, press Try again anyway
Connect HubSpotTheir HubSpot login was disconnectedPress Connect HubSpot, then Save to HubSpot again
"Saving to HubSpot is no longer turned on for this template."Saving was switched off after the PDF was madeTurn it on again, or download the PDF

If HubSpot took the file but refused the note, the message says so: the file sits privately in the Weft Docs folder of HubSpot's file manager, not on the record. Pressing Try again saves it again, on a new note.

Good to know

  • Weft keeps no copy of the saved PDF. It checks that the file is exactly the one it generated, then hands it to HubSpot.
  • Saving only ever adds — a new private file and a new note. Weft never changes or deletes anything in your HubSpot.

What next