Skip to main content

Print Gift Card from Custom Redemption Page

If you're building your own custom redemption flow, you'll want to handle cases where recipients are printing their gift cards.

Updated this week

If you've built a Custom Redemption Flow, then handling printed gift cards will be important. You can choose to use Givy's built in tool, or build one yourself.

Identifying Print Requests

If a customer chose to print their gift card, they'll receive an email with a Print button. This button will direct customers to the customer redemption page you created, with a URL variable of print=true. Your page should detect this variable and handle it accordingly.

You may also want to offer a print option for recipients who received their gifts via email, but who still want a physical copy of it. In this case, add a Print button somewhere on the redemption page.

Print Using Givy

Givy comes with a method to print a gift without any additional effort needed. To do this, you'll need the giftId from the redemption URL. To print a gift using Givy's tool, simply direct them to the following proxy page URL on your Shopify store:

htts://your-domain.com/a/givy/redeem/<giftId>/print

This URL will automatically launch the print dialog for the default printed format. We recommend looking for the print=true URL variable, and automatically directing them to this page if true.

Custom Print Format

Like everything in Givy, you have full control over how the printed page looks. To create a custom design, you will simply need to build a webpage with the design and information relevant to the gift, and call the window.print(); function to open the print dialog.

Some things to note:

  • We recommend waiting until all images have loaded before calling this function

  • You should either show the design being printed, or have a manual Print button in case recipients need to do it again

  • We recommend a fixed width of 1000px

To hide the design being printed, you could use some styling similar to this:

 <div
css={css`
@media print {
display: none;
}
@media screen {
display: block;
}
`}
>
{screenContent}
</div>
<div
css={css`
@media print {
display: block;
}
@media screen {
display: none;
}
`}
>
{printedContent}
</div>

Did this answer your question?