How can I gain -complete- control over ALL the content of a Subscription message? I want to change the default content when Quickbase sends a subscription email.

  • 0
  • 1
  • Question
  • Updated 4 years ago
  • Answered
Photo of Jack

Jack

  • 0 Points

Posted 4 years ago

  • 0
  • 1
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,224 Points 20k badge 2x thumb
You can't gain complete control of the format of Subscription messages. For security, loading, branding and probably other valid reasons we are not privy to, QuickBase has wisely chosen to send unadorned email messages. If you want greater control over the content that is sent you could try the following approach.

Instead of sending message based on your primary tables create a new table called Messages and arrange by script or relationships to fill this table with content formatted more like what you want your users to receive. Include hyperlinks in the records of your Messages table that point to the the primary tables. Then arrange for your subscriptions to go out based on the Messages table instead of one of your primary tables. The user will see information that is more under your control and formatting and the hyperlinks will direct them to your primary tables where the data of your application is actually maintained. 

Other wise you have to use an external service to query QuickBase for data and format and send emails - or perhaps one of the features with the ItDuzzit thingy will work.
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,224 Points 20k badge 2x thumb
Another approach might be to send an email notification using script. Take a look at this script and the two attached screenshots.

Pastie Database
https://haversineconsulting.quickbase.com/db/bgcwm2m4g?a=dr&rid=429

While the screenshot of my gmail shows a report you can you can mute the bulk of the report by using a dbid for an table which has no records in it (yeah I know this is kinda strange). What you gain is basically the ability to send arbitrary text (not HTML) with a custom subject on demand to an explicit list of recipients. This is as close as you can come to controlling the content of the email.

I send out message like this all day long using this technique ...

Corporate Ipsum
http://www.cipsum.com/

UPDATE1: The third screenshots shows you what you will receive if you use a empty table for the dbid.

UPDATE2: Maybe you could stuff a copy of the message into the Empty table so it looks less confusing. Then your user will see two copies of the message - one in plain text and one inside the embedded table. Play ...
Photo of Ⲇanom the ultimate (Dan Diebolt)

Ⲇanom the ultimate (Dan Diebolt), Champion

  • 30,224 Points 20k badge 2x thumb
Okay I think I nailed it - as best can be achieved.

Specify two messages in the script. One is the plain text message that sits atop the table report in the email Notification. The second message is generated by whatever means you want (including AJAX calls) and can support some HTML as this second message will actually be inserted as a new record in the Messages table. So instead of using an empty Messages table we will put our second message in a new record of the Messages table and send a report that lists only this one new message record. In effect we are bypassing QuickBase's limitation on including HTML in the message by jamming our HTML into the newly created Message record and sending this new record as the embedded report.

See new pastie code and the attached screenshot of the receive email. The hyperlink in the embedded report (look for "real-time schemas.") of the received email actually points to the Customer table not something in the Messages table which is what you want. This may be confusing but is actually quite a useful technique - I have to think of a snarky name for it. Hmmm ... How about calling this the "You Got Ipsum" technique? I like it!

Pastie Database
https://haversineconsulting.quickbase.com/db/bgcwm2m4g?a=dr&rid=431