Skip to main content
Question

Add Record with Webhooks and pull in file attachment field


Hello,

I am creating a webhook that fires off when a new file is attached to a record.  The webhook creates a new record in a documents table and populates some information.  It works, however I need a file attachment field to fill with the file from the other record.  Basically trying to create a history of documents based off of the file attachment field.  Here is my webhook currently:

<qdbapi>     <udata>mydata</udata>
     <usertoken>%user.token.xxxx_xxx_xxx.xxxxxx User Token%</usertoken>
     

<field fid="6">[Record ID#]</field>
     <field fid="10" >[File Link]</field>
   
     </qdbapi>
  
Thanks.
This topic has been closed for replies.

Would a link to the original record's file attachment work?

If not, for an API call (which is what webhooks are based on) file attachments have to be base-64 encoded and I'm not sure a process to do so has been built into webhooks yet.

  • Author
  • Registered
  • March 9, 2017
For this case the original records file attachment won't work because I am trying to track history through webhooks.  So yes this does mean that I will have to use the API call and base-64 encode the file.  I wasn't sure how to do that unfortunately.  

Then, unfortunately, I'm not aware of a way to accomplish this with the current version of webhooks. Some of our partners: http://www.quickbase.com/partners/add-ons who have file attachment add-ons might be able to direct you to a resource, or help setup the process you need.